From b5da073416f93f9f145ac9eb44794775fbf6a752 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 27 Apr 1995 06:06:46 +0000 Subject: [PATCH] merge with 1.11.f --- lib/getopt.c | 7 +++++-- lib/regex.c | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/lib/getopt.c b/lib/getopt.c index 57fd398ef..de30ec79f 100644 --- a/lib/getopt.c +++ b/lib/getopt.c @@ -3,7 +3,7 @@ "Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu before changing it! - Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94 + Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94, 95 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it @@ -383,7 +383,10 @@ _getopt_internal (argc, argv, optstring, longopts, longind, long_only) optarg = NULL; if (optind == 0) - optstring = _getopt_initialize (optstring); + { + optstring = _getopt_initialize (optstring); + optind = 1; /* Don't scan ARGV[0], the program name. */ + } if (nextchar == NULL || *nextchar == '\0') { diff --git a/lib/regex.c b/lib/regex.c index 37e67c6be..ec1b17ddf 100644 --- a/lib/regex.c +++ b/lib/regex.c @@ -2865,7 +2865,7 @@ re_compile_fastmap (bufp) /* This holds the pointer to the failure stack, when it is allocated relocatably. */ -#ifdef REL_ALLOC_STMT +#ifdef REL_ALLOC fail_stack_elt_t *failure_stack_ptr; #endif @@ -3518,7 +3518,7 @@ re_match_2_internal (bufp, string1, size1, string2, size2, pos, regs, stop) /* This holds the pointer to the failure stack, when it is allocated relocatably. */ -#ifdef REL_ALLOC_STMT +#ifdef REL_ALLOC fail_stack_elt_t *failure_stack_ptr; #endif -- 2.11.0