Trinity fuzzer tool discussions
 help / color / mirror / Atom feed
* [PATCH] ioctls: btrfs-control: fix header inclusion order
@ 2013-07-23 19:35 Andi Shyti
  2013-07-23 23:30 ` Andi Shyti
  0 siblings, 1 reply; 5+ messages in thread
From: Andi Shyti @ 2013-07-23 19:35 UTC (permalink / raw)
  To: tt.rantala; +Cc: trinity, mikko.rapeli, andi

This patch enables older linux/btrfs.h where NULL is not
recognized as a define. It gets rid of the following compiling
error:

In file included from ioctls/btrfs-control.c:5:0:
/usr/include/linux/btrfs.h: In function ‘btrfs_err_str’:
/usr/include/linux/btrfs.h:486:11: error: ‘NULL’ undeclared (first use in this function)
    return NULL;
           ^

This is done by postponing the inclusion of btrf.h

Signed-off-by: Andi Shyti <andi@etezian.org>
---
 ioctls/btrfs-control.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ioctls/btrfs-control.c b/ioctls/btrfs-control.c
index 35e5389..8d1e2d9 100644
--- a/ioctls/btrfs-control.c
+++ b/ioctls/btrfs-control.c
@@ -2,11 +2,11 @@
 
 #ifdef USE_BTRFS
 
-#include <linux/btrfs.h>
-
 #include "trinity.h"
 #include "ioctls.h"
 
+#include <linux/btrfs.h>
+
 static const struct ioctl btrfs_control_ioctls[] = {
 	IOCTL(BTRFS_IOC_SCAN_DEV),
 	IOCTL(BTRFS_IOC_DEVICES_READY),
-- 
1.8.3.2

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-07-24 10:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-23 19:35 [PATCH] ioctls: btrfs-control: fix header inclusion order Andi Shyti
2013-07-23 23:30 ` Andi Shyti
2013-07-23 23:39   ` [PATCH v2] " Andi Shyti
2013-07-24  6:56     ` Tommi Rantala
2013-07-24 10:31       ` [PATCH v3] " Andi Shyti

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox