aboutsummaryrefslogtreecommitdiff
path: root/debianutils/run_parts.c
diff options
context:
space:
mode:
Diffstat (limited to 'debianutils/run_parts.c')
-rw-r--r--debianutils/run_parts.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/debianutils/run_parts.c b/debianutils/run_parts.c
index 34e702ef8..a6ad81096 100644
--- a/debianutils/run_parts.c
+++ b/debianutils/run_parts.c
@@ -88,7 +88,6 @@ int run_parts_main(int argc, char **argv)
* Called once for every argument. */
args = xrealloc(args, (argcount + 2) * (sizeof(char *)));
args[argcount++] = optarg;
- args[argcount] = 0;
break;
default:
show_usage();
@@ -101,5 +100,7 @@ int run_parts_main(int argc, char **argv)
}
args[0] = argv[optind];
+ args[argcount] = 0;
+
return(run_parts(args, test_mode));
}