[glib/wip/3v1n0/support-can-fail-tests: 8/9] glocalfileinfo: Define errsv only if it's used
- From: Marco Trevisan <marcotrevi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/wip/3v1n0/support-can-fail-tests: 8/9] glocalfileinfo: Define errsv only if it's used
- Date: Thu, 20 Oct 2022 00:33:42 +0000 (UTC)
commit 1b712ffdb4272ae8d14ec616fac5cb6b0963c143
Author: Marco Trevisan (TreviƱo) <mail 3v1n0 net>
Date: Thu Oct 20 00:32:17 2022 +0200
glocalfileinfo: Define errsv only if it's used
gio/glocalfileinfo.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/gio/glocalfileinfo.c b/gio/glocalfileinfo.c
index 661d2266ab..bfc25504f6 100644
--- a/gio/glocalfileinfo.c
+++ b/gio/glocalfileinfo.c
@@ -1385,7 +1385,10 @@ get_content_type (const char *basename,
{
guchar sniff_buffer[4096];
gsize sniff_length;
- int fd, errsv;
+#ifdef O_NOATIME
+ int errsv;
+#endif
+ int fd;
sniff_length = _g_unix_content_type_get_sniff_len ();
if (sniff_length == 0 || sniff_length > 4096)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]