Whamcloud - gitweb
Fix miscellaneous compile warnings
authorAndreas Dilger <adilger@sun.com>
Mon, 25 Aug 2008 00:37:39 +0000 (20:37 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 25 Aug 2008 00:37:39 +0000 (20:37 -0400)
Signed-off-by: Andreas Dilger <adilger@sun.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
e2fsck/unix.c
lib/blkid/read.c

index 41aa99b..be57684 100644 (file)
@@ -48,6 +48,7 @@ extern int optind;
 #include <dirent.h>
 #endif
 
+#include "e2p/e2p.h"
 #include "et/com_err.h"
 #include "e2p/e2p.h"
 #include "e2fsck.h"
index dad6147..b913b63 100644 (file)
@@ -10,6 +10,8 @@
  * %End-Header%
  */
 
+#define _XOPEN_SOURCE 600 /* for inclusion of strtoull */
+
 #include <stdio.h>
 #include <ctype.h>
 #include <string.h>
@@ -26,7 +28,6 @@
 #include "uuid/uuid.h"
 
 #ifdef HAVE_STRTOULL
-#define __USE_ISOC9X
 #define STRTOULL strtoull /* defined in stdlib.h if you try hard enough */
 #else
 /* FIXME: need to support real strtoull here */
@@ -319,8 +320,7 @@ static int parse_tag(blkid_cache cache, blkid_dev dev, char **cp)
        else if (!strcmp(name, "PRI"))
                dev->bid_pri = strtol(value, 0, 0);
        else if (!strcmp(name, "TIME"))
-               /* FIXME: need to parse a long long eventually */
-               dev->bid_time = strtol(value, 0, 0);
+               dev->bid_time = STRTOULL(value, 0, 0);
        else
                ret = blkid_set_tag(dev, name, value, strlen(value));