Fix min/max typeof warnings
authorJens Axboe <axboe@fb.com>
Tue, 23 Sep 2014 16:38:54 +0000 (10:38 -0600)
committerJens Axboe <axboe@fb.com>
Tue, 23 Sep 2014 16:38:54 +0000 (10:38 -0600)
Signed-off-by: Jens Axboe <axboe@fb.com>
lib/axmap.c
lib/zipf.c
parse.c

index 15cd635037a0bdfc565b26c1f2502180eae831af..5b8cb3094d88d6bb6cc6317b5d8c36fc49f502ff 100644 (file)
@@ -33,7 +33,7 @@
 #error "Number of arch bits unknown"
 #endif
 
-#define BLOCKS_PER_UNIT                (1UL << UNIT_SHIFT)
+#define BLOCKS_PER_UNIT                (1U << UNIT_SHIFT)
 #define BLOCKS_PER_UNIT_MASK   (BLOCKS_PER_UNIT - 1)
 
 #define firstfree_valid(b)     ((b)->first_free != (uint64_t) -1)
index 9b6ce6334836baa1f0f3c0c238da24f319ad4c3b..e75dc2aa64409f923daeede3d28941da57b38f4e 100644 (file)
@@ -11,7 +11,7 @@
 #include "../minmax.h"
 #include "../hash.h"
 
-#define ZIPF_MAX_GEN   10000000
+#define ZIPF_MAX_GEN   10000000UL
 
 static void zipf_update(struct zipf_state *zs)
 {
diff --git a/parse.c b/parse.c
index e6d9406e1612231a295516eab1bde32e72bd8a37..40cd46587d3e03477451fd3ef2aaa8b832c6ef1a 100644 (file)
--- a/parse.c
+++ b/parse.c
@@ -380,7 +380,7 @@ static int check_int(const char *p, int *val)
        return 1;
 }
 
-static int opt_len(const char *str)
+static size_t opt_len(const char *str)
 {
        char *postfix;