Commit 250fce1d by Tom Tromey Committed by Tom Tromey

jartool.c (main): NULL-terminate new_argv.

	* jartool.c (main): NULL-terminate new_argv.  Pass 0 as argument
	to init_args.

From-SVN: r49351
parent 2083b5be
2002-01-30 Tom Tromey <tromey@redhat.com>
* jartool.c (main): NULL-terminate new_argv. Pass 0 as argument
to init_args.
2002-01-11 Tom Tromey <tromey@redhat.com> 2002-01-11 Tom Tromey <tromey@redhat.com>
* Makefile.in: Rebuilt. * Makefile.in: Rebuilt.
......
...@@ -404,6 +404,7 @@ int main(int argc, char **argv){ ...@@ -404,6 +404,7 @@ int main(int argc, char **argv){
all following options are handled as file names. */ all following options are handled as file names. */
while (optind < argc) while (optind < argc)
new_argv[new_argc++] = argv[optind++]; new_argv[new_argc++] = argv[optind++];
new_argv[new_argc] = NULL;
if(action == ACTION_NONE){ if(action == ACTION_NONE){
fprintf(stderr, "One of options -{ctxu} must be specified.\n"); fprintf(stderr, "One of options -{ctxu} must be specified.\n");
...@@ -495,7 +496,7 @@ int main(int argc, char **argv){ ...@@ -495,7 +496,7 @@ int main(int argc, char **argv){
else if(manifest) else if(manifest)
make_manifest(jarfd, NULL); make_manifest(jarfd, NULL);
init_args (new_argv, new_argc); init_args (new_argv, 0);
/* now we add the files to the archive */ /* now we add the files to the archive */
while ((arg = get_next_arg ())){ while ((arg = get_next_arg ())){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment