]> git.proxmox.com Git - mirror_iproute2.git/commitdiff
remove redundant long int
authorStephen Hemminger <stephen@networkplumber.org>
Mon, 10 Dec 2018 17:21:17 +0000 (09:21 -0800)
committerStephen Hemminger <stephen@networkplumber.org>
Thu, 13 Dec 2018 19:36:59 +0000 (11:36 -0800)
Using unsigned long is sufficient no need to be more
verbose and use unsigned long int.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
include/json_print.h
include/json_writer.h
lib/json_print.c
lib/json_writer.c
lib/utils.c

index 218da31a73fe876321b2a9aac7a5f741d3fb586d..ee087c3e627a73ffc70de465f7e94325ef824e21 100644 (file)
@@ -66,9 +66,9 @@ _PRINT_FUNC(uint, unsigned int);
 _PRINT_FUNC(u64, uint64_t);
 _PRINT_FUNC(hu, unsigned short);
 _PRINT_FUNC(hex, unsigned int);
-_PRINT_FUNC(0xhex, unsigned long long int);
-_PRINT_FUNC(luint, unsigned long int);
-_PRINT_FUNC(lluint, unsigned long long int);
+_PRINT_FUNC(0xhex, unsigned long long);
+_PRINT_FUNC(luint, unsigned long);
+_PRINT_FUNC(lluint, unsigned long long);
 _PRINT_FUNC(float, double);
 #undef _PRINT_FUNC
 
index 0c8831c1136df2bcefca9febcc31ceeb5b672c89..17d409e0557d3b7d30a7456e1db13073dbc209ad 100644 (file)
@@ -42,8 +42,8 @@ void jsonw_hu(json_writer_t *self, unsigned short number);
 void jsonw_int(json_writer_t *self, int number);
 void jsonw_s64(json_writer_t *self, int64_t number);
 void jsonw_null(json_writer_t *self);
-void jsonw_luint(json_writer_t *self, unsigned long int num);
-void jsonw_lluint(json_writer_t *self, unsigned long long int num);
+void jsonw_luint(json_writer_t *self, unsigned long num);
+void jsonw_lluint(json_writer_t *self, unsigned long long num);
 
 /* Useful Combinations of name and value */
 void jsonw_string_field(json_writer_t *self, const char *prop, const char *val);
@@ -57,9 +57,9 @@ void jsonw_int_field(json_writer_t *self, const char *prop, int num);
 void jsonw_s64_field(json_writer_t *self, const char *prop, int64_t num);
 void jsonw_null_field(json_writer_t *self, const char *prop);
 void jsonw_luint_field(json_writer_t *self, const char *prop,
-                       unsigned long int num);
+                       unsigned long num);
 void jsonw_lluint_field(json_writer_t *self, const char *prop,
-                       unsigned long long int num);
+                       unsigned long long num);
 
 /* Collections */
 void jsonw_start_object(json_writer_t *self);
index f7ef41c1570f2a72eacd213e278193036b3dc561..54fa40cff142762b94aadc3b855e83d5c3ecfb10 100644 (file)
@@ -121,8 +121,8 @@ _PRINT_FUNC(s64, int64_t);
 _PRINT_FUNC(hu, unsigned short);
 _PRINT_FUNC(uint, unsigned int);
 _PRINT_FUNC(u64, uint64_t);
-_PRINT_FUNC(luint, unsigned long int);
-_PRINT_FUNC(lluint, unsigned long long int);
+_PRINT_FUNC(luint, unsigned long);
+_PRINT_FUNC(lluint, unsigned long long);
 _PRINT_FUNC(float, double);
 #undef _PRINT_FUNC
 
index 68890b34ee92f583ee9eb8497bcb7156adf14748..5779ec067daa2fd36019987e813c89605cc47fe8 100644 (file)
@@ -231,12 +231,12 @@ void jsonw_xint(json_writer_t *self, uint64_t num)
        jsonw_printf(self, "%"PRIx64, num);
 }
 
-void jsonw_luint(json_writer_t *self, unsigned long int num)
+void jsonw_luint(json_writer_t *self, unsigned long num)
 {
        jsonw_printf(self, "%lu", num);
 }
 
-void jsonw_lluint(json_writer_t *self, unsigned long long int num)
+void jsonw_lluint(json_writer_t *self, unsigned long long num)
 {
        jsonw_printf(self, "%llu", num);
 }
@@ -296,7 +296,7 @@ void jsonw_hu_field(json_writer_t *self, const char *prop, unsigned short num)
 
 void jsonw_luint_field(json_writer_t *self,
                        const char *prop,
-                       unsigned long int num)
+                       unsigned long num)
 {
        jsonw_name(self, prop);
        jsonw_luint(self, num);
@@ -304,7 +304,7 @@ void jsonw_luint_field(json_writer_t *self,
 
 void jsonw_lluint_field(json_writer_t *self,
                        const char *prop,
-                       unsigned long long int num)
+                       unsigned long long num)
 {
        jsonw_name(self, prop);
        jsonw_lluint(self, num);
index 4965a575088079916a2dc6319badfdd6db6f8479..84733890587d234b792ab2745f6d566ccdbfc3c5 100644 (file)
@@ -1478,7 +1478,7 @@ char *int_to_str(int val, char *buf)
 
 int get_guid(__u64 *guid, const char *arg)
 {
-       unsigned long int tmp;
+       unsigned long tmp;
        char *endptr;
        int i;