openbsd-ports/devel/dconf/patches/patch-common_dconf-shmdir_c
2011-05-05 08:33:30 +00:00

31 lines
722 B
Plaintext

$OpenBSD: patch-common_dconf-shmdir_c,v 1.4 2011/05/05 08:33:30 ajacoutot Exp $
--- common/dconf-shmdir.c.orig Tue Jan 18 06:48:15 2011
+++ common/dconf-shmdir.c Thu May 5 10:28:49 2011
@@ -21,11 +21,13 @@
#include "dconf-shmdir.h"
-#ifndef __FreeBSD__
+#if !(defined __FreeBSD__ || defined __OpenBSD__)
#include <sys/statfs.h>
#include <sys/vfs.h>
#endif
+#include <string.h>
+
#include <sys/param.h>
#include <sys/mount.h>
#include <errno.h>
@@ -53,7 +55,11 @@ is_local (const gchar *filename)
while (s < 0 && errno == EINTR);
}
+#ifndef __OpenBSD__
return s == 0 && buf.f_type != NFS_SUPER_MAGIC;
+#else
+ return s == 0 && strcmp(buf.f_fstypename, MOUNT_NFS) != 0;
+#endif
}
gchar *