MSG
} type_id;
-static int remove_ids(type_id type, int argc, char **argv)
+static int remove_ids(type_id type, char **argv)
{
unsigned long id;
int nb_errors = 0;
arg.val = 0;
- while (argc) {
+ while (argv[0]) {
id = bb_strtoul(argv[0], NULL, 10);
if (errno || id > INT_MAX) {
bb_error_msg("invalid id: %s", argv[0]);
nb_errors++;
}
}
- argc--;
argv++;
}
else if (w == 'e')
what = SEM;
- if (remove_ids(what, argc-2, &argv[2]))
+ if (remove_ids(what, &argv[2]))
fflush_stdout_and_exit(EXIT_FAILURE);
printf("resource(s) deleted\n");
return 0;