Fix incorrect usage of getopt_long(), which caused
authorLasse Collin <lasse.collin@tukaani.org>
Thu, 23 Jul 2009 16:10:55 +0000 (19:10 +0300)
committerLasse Collin <lasse.collin@tukaani.org>
Thu, 23 Jul 2009 16:10:55 +0000 (19:10 +0300)
invalid memory access if XZ_OPT was defined.

src/xz/args.c

index 8d5d33c..b50e28b 100644 (file)
@@ -489,7 +489,6 @@ args_parse(args_info *args, int argc, char **argv)
        parse_environment(args, argv[0]);
 
        // Then from the command line
-       optind = 1;
        parse_real(args, argc, argv);
 
        // Never remove the source file when the destination is not on disk.