]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/resolve/resolvectl.c
tree-wide: be more careful with the type of array sizes
[thirdparty/systemd.git] / src / resolve / resolvectl.c
index 1b7c64a83a06d67896aaee11f61972c1c1c00cd5..0b58e9b57fd6c1fc89c6f0ef40e6f73d5154f515 100644 (file)
@@ -2865,9 +2865,9 @@ static int native_main(int argc, char *argv[], sd_bus *bus) {
         return dispatch_verb(argc, argv, verbs, bus);
 }
 
-static int translate(const char *verb, const char *single_arg, unsigned num_args, char **args, sd_bus *bus) {
+static int translate(const char *verb, const char *single_arg, size_t num_args, char **args, sd_bus *bus) {
         char **fake, **p;
-        unsigned num, i;
+        size_t num, i;
 
         assert(verb);
         assert(num_args == 0 || args);
@@ -2882,7 +2882,7 @@ static int translate(const char *verb, const char *single_arg, unsigned num_args
                 *p++ = args[i];
 
         optind = 0;
-        return native_main(num, fake, bus);
+        return native_main((int) num, fake, bus);
 }
 
 static int compat_main(int argc, char *argv[], sd_bus *bus) {