]> git.sur5r.net Git - i3/i3status/commitdiff
Fix disk usage on OpenBSD.
authorJasper Lievisse Adriaanse <jasper@humppa.nl>
Fri, 27 Apr 2012 16:48:22 +0000 (18:48 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Sun, 29 Apr 2012 09:13:14 +0000 (11:13 +0200)
src/print_disk_info.c

index 9ddffd3e68d17b4c95386c71ab90b71ece4fcfbb..8bc8b4116ebfdd4f2440e8c360b32e6254420a75 100644 (file)
@@ -6,7 +6,7 @@
 #include <stdint.h>
 #include <sys/statvfs.h>
 #include <sys/types.h>
-#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || (__OpenBSD__)
 #include <sys/param.h>
 #include <sys/mount.h>
 #endif
@@ -49,7 +49,7 @@ void print_disk_info(yajl_gen json_gen, char *buffer, const char *path, const ch
 
         INSTANCE(path);
 
-#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__)
         struct statfs buf;
 
         if (statfs(path, &buf) == -1)