gnulib.git
18 years ago* lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
Paul Eggert [Wed, 31 Aug 2005 19:38:13 +0000 (19:38 +0000)]
* lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
(optimize_subexps, lower_subexp):
Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
since the signed shift might overflow.  Use 1u<<31 instead.
* lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
Likewise.
* lib/regexec.c (check_dst_limits_calc_pos_1):
(check_subexp_matching_top): Likewise.
* lib/regcomp.c (optimize_subexps, lower_subexp):
Use CHAR_BIT rather than 8, for clarity.
* lib/regexec.c (check_dst_limits_calc_pos_1):
(check_subexp_matching_top): Likewise.
* lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
have to worry about portability issues when shifting it left.
Remove no-longer-needed test for table_size > 0.
* lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
in a word, as the resulting behavior is undefined.
* lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
in one case, a <= should have been an <, and in another case the
whole test was missing.
* lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
the standard name CHAR_BIT.
* lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
this is not true on one's complement and signed-magnitude hosts.

18 years ago* lib/regex_internal.h (re_sub_match_top_t): Remove unused member
Paul Eggert [Wed, 31 Aug 2005 18:08:34 +0000 (18:08 +0000)]
* lib/regex_internal.h (re_sub_match_top_t): Remove unused member
next_last_offset.
(struct re_dfa_t): Remove unused member states_alloc.
* lib/regcomp.c (init_dfa): Don't initialize unused members.
* config/srclist.txt: Add glibc bug 1273.

18 years ago*** empty log message ***
Jim Meyering [Wed, 31 Aug 2005 15:56:30 +0000 (15:56 +0000)]
*** empty log message ***

18 years agoAdd a FIXME comment.
Jim Meyering [Wed, 31 Aug 2005 15:56:01 +0000 (15:56 +0000)]
Add a FIXME comment.

18 years ago*** empty log message ***
Jim Meyering [Wed, 31 Aug 2005 15:39:56 +0000 (15:39 +0000)]
*** empty log message ***

18 years ago(Files): Add stdio--.h.
Jim Meyering [Wed, 31 Aug 2005 15:39:48 +0000 (15:39 +0000)]
(Files): Add stdio--.h.

18 years ago(Files): Add unistd--.h.
Jim Meyering [Wed, 31 Aug 2005 15:39:33 +0000 (15:39 +0000)]
(Files): Add unistd--.h.

18 years agoInclude a header, to define NULL.
Bruno Haible [Wed, 31 Aug 2005 11:51:18 +0000 (11:51 +0000)]
Include a header, to define NULL.

18 years ago* iconvme.h: Add prototype for iconv_alloc.
Simon Josefsson [Tue, 30 Aug 2005 07:38:53 +0000 (07:38 +0000)]
* iconvme.h: Add prototype for iconv_alloc.

18 years ago.
Karl Berry [Tue, 30 Aug 2005 07:36:01 +0000 (07:36 +0000)]
.

18 years agoAvoid unnecessary spaces in $avoidlist.
Bruno Haible [Mon, 29 Aug 2005 20:03:01 +0000 (20:03 +0000)]
Avoid unnecessary spaces in $avoidlist.

18 years agoEmit more comments and advice.
Bruno Haible [Mon, 29 Aug 2005 20:02:25 +0000 (20:02 +0000)]
Emit more comments and advice.

18 years agoProtect references to destdir with double-quotes.
Bruno Haible [Mon, 29 Aug 2005 19:59:56 +0000 (19:59 +0000)]
Protect references to destdir with double-quotes.

18 years ago*** empty log message ***
Jim Meyering [Mon, 29 Aug 2005 11:57:22 +0000 (11:57 +0000)]
*** empty log message ***

18 years agoIf more parameters are given, check each of them
Jim Meyering [Mon, 29 Aug 2005 11:57:17 +0000 (11:57 +0000)]
If more parameters are given, check each of them
separately; add more exceptions, as noted by Jim Meyering.
(check_module): New procedure.
(%exempt_header): Now contains all exceptions.

18 years agoFix rule to not assume GNU make.
Bruno Haible [Mon, 29 Aug 2005 11:13:56 +0000 (11:13 +0000)]
Fix rule to not assume GNU make.

18 years agoFix, spotted by Stepan Kasal.
Bruno Haible [Mon, 29 Aug 2005 11:08:46 +0000 (11:08 +0000)]
Fix, spotted by Stepan Kasal.

18 years agoFix typo in description, spotted by Stepan Kasal.
Bruno Haible [Mon, 29 Aug 2005 11:01:04 +0000 (11:01 +0000)]
Fix typo in description, spotted by Stepan Kasal.

18 years ago* iconvme.c: Fix errno.
Simon Josefsson [Mon, 29 Aug 2005 08:09:21 +0000 (08:09 +0000)]
* iconvme.c: Fix errno.
* iconvme.c: Split iconv_string into iconv_alloc.

18 years ago.
Karl Berry [Sun, 28 Aug 2005 07:34:41 +0000 (07:34 +0000)]
.

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 20:49:48 +0000 (20:49 +0000)]
*** empty log message ***

18 years agoMerge minor changes from coreutils.
Jim Meyering [Sat, 27 Aug 2005 20:49:12 +0000 (20:49 +0000)]
Merge minor changes from coreutils.

18 years agoMerge from coreutils: New file.
Jim Meyering [Sat, 27 Aug 2005 20:46:51 +0000 (20:46 +0000)]
Merge from coreutils: New file.

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 20:39:01 +0000 (20:39 +0000)]
*** empty log message ***

18 years agoincrement serial number
Jim Meyering [Sat, 27 Aug 2005 20:38:27 +0000 (20:38 +0000)]
increment serial number

18 years ago(gl_STDIO_SAFER): Add stdio--.h.
Jim Meyering [Sat, 27 Aug 2005 20:38:08 +0000 (20:38 +0000)]
(gl_STDIO_SAFER): Add stdio--.h.

18 years agoNew file. From coreutils.
Jim Meyering [Sat, 27 Aug 2005 20:37:14 +0000 (20:37 +0000)]
New file.  From coreutils.

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 20:35:39 +0000 (20:35 +0000)]
*** empty log message ***

18 years agoAdd pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
Jim Meyering [Sat, 27 Aug 2005 20:35:21 +0000 (20:35 +0000)]
Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.

18 years agoMerge from coreutils: New file.
Jim Meyering [Sat, 27 Aug 2005 20:12:02 +0000 (20:12 +0000)]
Merge from coreutils: New file.

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 20:06:29 +0000 (20:06 +0000)]
*** empty log message ***

18 years ago(pipe): Define to pipe_safer.
Jim Meyering [Sat, 27 Aug 2005 20:06:18 +0000 (20:06 +0000)]
(pipe): Define to pipe_safer.

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 14:37:32 +0000 (14:37 +0000)]
*** empty log message ***

18 years ago(gl_UNISTD_SAFER): Add pipe-safer.c.
Jim Meyering [Sat, 27 Aug 2005 14:37:07 +0000 (14:37 +0000)]
(gl_UNISTD_SAFER): Add pipe-safer.c.

18 years ago(gl_FCNTL_SAFER): Add creat-safer.c to the
Jim Meyering [Sat, 27 Aug 2005 14:35:43 +0000 (14:35 +0000)]
(gl_FCNTL_SAFER): Add creat-safer.c to the
AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.

18 years ago(Files): Add creat-safer.c.
Jim Meyering [Sat, 27 Aug 2005 14:29:31 +0000 (14:29 +0000)]
(Files): Add creat-safer.c.

18 years ago(Files): Add pipe-safer.c
Jim Meyering [Sat, 27 Aug 2005 14:29:15 +0000 (14:29 +0000)]
(Files): Add pipe-safer.c

18 years ago*** empty log message ***
Jim Meyering [Sat, 27 Aug 2005 14:29:00 +0000 (14:29 +0000)]
*** empty log message ***

18 years agoDeclare pipe_safer.
Jim Meyering [Sat, 27 Aug 2005 14:28:43 +0000 (14:28 +0000)]
Declare pipe_safer.

18 years agoInclude <sys/types.h> and declare creat_safer.
Jim Meyering [Sat, 27 Aug 2005 14:28:28 +0000 (14:28 +0000)]
Include <sys/types.h> and declare creat_safer.

18 years ago(creat): Define to creat_safer.
Jim Meyering [Sat, 27 Aug 2005 14:28:10 +0000 (14:28 +0000)]
(creat): Define to creat_safer.

18 years agoGNU tar needs these.
Jim Meyering [Sat, 27 Aug 2005 14:27:24 +0000 (14:27 +0000)]
GNU tar needs these.

18 years ago* config/srclist.text: Add glibc bug 1248.
Paul Eggert [Fri, 26 Aug 2005 21:47:51 +0000 (21:47 +0000)]
* config/srclist.text: Add glibc bug 1248.
* lib/regex_internal.h: Remove all references to
RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
or better.
(bitset_not, bitset_merge, bitset_not_merge):
(bitset_mask, re_string_allocate, re_string_construct):
(re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
(re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
(re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
(re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
(re_node_set_init_union, re_node_set_merge, re_node_set_insert):
(re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
(re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
(re_acquire_state_context):
Remove unnecessary forward decls.
(re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
Put __attribute at function definition,
now that the function decl has been removed.
* lib/regex_internal.c (re_string_peek_byte_case):
(re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
Likewise.

18 years ago* getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
Simon Josefsson [Fri, 26 Aug 2005 12:33:59 +0000 (12:33 +0000)]
* getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
Haible <bruno@clisp.org>.

18 years ago.
Karl Berry [Fri, 26 Aug 2005 07:36:33 +0000 (07:36 +0000)]
.

18 years agoFix typo: __LIBC -> _LIBC.
Paul Eggert [Fri, 26 Aug 2005 06:08:46 +0000 (06:08 +0000)]
Fix typo: __LIBC -> _LIBC.

18 years ago* config/srclist.txt: Add glibc bug 1245.
Paul Eggert [Fri, 26 Aug 2005 05:58:54 +0000 (05:58 +0000)]
* config/srclist.txt: Add glibc bug 1245.

* lib/regexec.c (set_regs): Don't alloca with an unbounded size.

alloca modernization/simplification for regex.
* lib/regex.c: Remove portability cruft for alloca.  This no longer
needs to be at the start of the file, and can be moved into
regex_internal.h and simplified.
* lib/regex_internal.h: Include <alloca.h>.
(__libc_use_alloca) [!defined _LIBC]: New macro.
* lib/regexec.c (build_trtable): Remove "#ifdef _LIBC",
since the code now works outside glibc.

18 years ago* getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
Simon Josefsson [Thu, 25 Aug 2005 21:19:07 +0000 (21:19 +0000)]
* getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
__fsetlocking.

18 years ago* getpass.c: Add WIN32 implementation. Conditionalize use of
Simon Josefsson [Thu, 25 Aug 2005 21:18:50 +0000 (21:18 +0000)]
* getpass.c: Add WIN32 implementation.  Conditionalize use of
termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
GLIBC specific code.

18 years agoUse m4_pushdef/m4_popdef and AS_TR_SH, AS_TR_CPP.
Bruno Haible [Thu, 25 Aug 2005 20:57:11 +0000 (20:57 +0000)]
Use m4_pushdef/m4_popdef and AS_TR_SH, AS_TR_CPP.

18 years ago* m4/regex.m4: Add AC_PREREQ(2.50).
Paul Eggert [Thu, 25 Aug 2005 20:54:03 +0000 (20:54 +0000)]
* m4/regex.m4: Add AC_PREREQ(2.50).
(gl_REGEX): If --with-included-regex was given, skip the autodetection.

18 years agoAdd comment.
Bruno Haible [Thu, 25 Aug 2005 20:42:45 +0000 (20:42 +0000)]
Add comment.

18 years agoMake regex safe for g++. This fixes one real bug (an "err"
Paul Eggert [Thu, 25 Aug 2005 20:39:57 +0000 (20:39 +0000)]
Make regex safe for g++.  This fixes one real bug (an "err"
that should have been "*err").
* config/srclist.txt: Add glibc bug 1241.
* lib/regex_internal.h (re_calloc): New macro, consistent with
re_malloc etc.  All callers of calloc changed to use re_calloc.
* lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
not int.  All callers changed.
* lib/regcomp.c (re_compile_fastmap_iter): Don't use alloca
(mb_cur_max); just use an array of size MB_LEN_MAX.
* lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
(find_recover_state): Change "err" to "*err"; this fixes what
appears to be a real bug.
(check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
versus int.

18 years ago* modules/regex (Depends-on): Add malloc, since the code
Paul Eggert [Thu, 25 Aug 2005 19:45:05 +0000 (19:45 +0000)]
* modules/regex (Depends-on): Add malloc, since the code
assumes that !malloc(0) means failure.

18 years ago*** empty log message ***
Jim Meyering [Thu, 25 Aug 2005 16:30:08 +0000 (16:30 +0000)]
*** empty log message ***

18 years agoInclude <config.h>.
Jim Meyering [Thu, 25 Aug 2005 16:30:01 +0000 (16:30 +0000)]
Include <config.h>.
Otherwise, we'd lose LARGEFILE support in any file using e.g. "fcntl--.h"

18 years agoTests for module 'tls'.
Bruno Haible [Thu, 25 Aug 2005 12:40:25 +0000 (12:40 +0000)]
Tests for module 'tls'.

18 years agoTests for gnulib module 'lock'.
Bruno Haible [Thu, 25 Aug 2005 12:36:58 +0000 (12:36 +0000)]
Tests for gnulib module 'lock'.

18 years agoSupport for unit test modules.
Bruno Haible [Thu, 25 Aug 2005 12:36:00 +0000 (12:36 +0000)]
Support for unit test modules.

18 years agoTemplate for tests module description.
Bruno Haible [Thu, 25 Aug 2005 12:17:21 +0000 (12:17 +0000)]
Template for tests module description.

18 years agoUpdate copyright year and authors.
Bruno Haible [Thu, 25 Aug 2005 12:15:37 +0000 (12:15 +0000)]
Update copyright year and authors.

18 years agoFix autoreconf invocation.
Bruno Haible [Thu, 25 Aug 2005 12:11:12 +0000 (12:11 +0000)]
Fix autoreconf invocation.

18 years agoGeneralize support for --aux-dir.
Bruno Haible [Thu, 25 Aug 2005 12:08:21 +0000 (12:08 +0000)]
Generalize support for --aux-dir.

18 years agoUse compound statement instead of subshell.
Bruno Haible [Thu, 25 Aug 2005 12:02:37 +0000 (12:02 +0000)]
Use compound statement instead of subshell.

18 years agoChange --aux-dir default to "build-aux".
Bruno Haible [Thu, 25 Aug 2005 12:00:38 +0000 (12:00 +0000)]
Change --aux-dir default to "build-aux".

18 years agoProper autoconf macro argument quoting.
Bruno Haible [Thu, 25 Aug 2005 11:56:57 +0000 (11:56 +0000)]
Proper autoconf macro argument quoting.

18 years ago.
Karl Berry [Thu, 25 Aug 2005 07:41:09 +0000 (07:41 +0000)]
.

18 years ago* config/srclist.txt: Add glibc bug 1240.
Paul Eggert [Thu, 25 Aug 2005 05:08:59 +0000 (05:08 +0000)]
* config/srclist.txt: Add glibc bug 1240.
* lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
* lib/regex.h (regerror): Likewise.

18 years agoFix typo in previous log entry.
Paul Eggert [Wed, 24 Aug 2005 23:43:46 +0000 (23:43 +0000)]
Fix typo in previous log entry.

18 years ago* srclist.txt: Comment out lib/regex.c. Add glibc bug 1238.
Paul Eggert [Wed, 24 Aug 2005 23:43:00 +0000 (23:43 +0000)]
* srclist.txt: Comment out lib/regex.c.  Add glibc bug 1238.
* lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
requires this.  (The code never needed it.)

18 years ago* config/srclist.txt: Add glibc bug 1237.
Paul Eggert [Wed, 24 Aug 2005 23:29:39 +0000 (23:29 +0000)]
* config/srclist.txt: Add glibc bug 1237.
* lib/regcomp.c, lib/regex_internal.c, lib/regex_internal.h:
* lib/regexec.c:
All uses of recently-renamed identifiers changed to use the new,
POSIX-compliant names.  The code will build and run just fine
without these changes, but it's better to eat our own dog food
and use the standard-conforming names.
* m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
for GNU regex features.

18 years ago[_REGEX_SOURCE]: Define re_fastmap_accurate too; this was
Paul Eggert [Wed, 24 Aug 2005 23:09:33 +0000 (23:09 +0000)]
[_REGEX_SOURCE]: Define re_fastmap_accurate too; this was
inadvertently omitted from the previous patch.

18 years ago* config/srclist.txt:
Paul Eggert [Wed, 24 Aug 2005 22:29:38 +0000 (22:29 +0000)]
* config/srclist.txt:
Remove glibc bug 1233 and add 1236, which supersedes it.

* lib/regex.h: Fix a multitude of POSIX name space violations.
These changes have an effect only for programs that define
_POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
do not change anything for programs compiled in the normal way.
Also, there is no effect on the ABI.

(_REGEX_SOURCE): New macro.
Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
defined and _GNU_SOURCE is not; this fixes a name space violation.

Rename the following macros to obey POSIX requirements.
The old names are still visible as macros if _REGEX_SOURCE is defined.
(REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
RE_BACKSLASH_ESCAPE_IN_LISTS.
(REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
(REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
(REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
(REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
(REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
(REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
(REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
(REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
(REG_INTERVALS): renamed from RE_INTERVALS.
(REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
(REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
(REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
(REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
(REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
(REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
(REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
(REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
RE_UNMATCHED_RIGHT_PAREN_ORD.
(REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
(REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
(REG_DEBUG): renamed from RE_DEBUG.
(REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
(REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
unusual, since we can't clash with the POSIX REG_ICASE.
(REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
(REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
(REG_NO_SUB): renamed from RE_NO_SUB.
(REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
(REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
(REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
(REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
(REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
(REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
(REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
(REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
(REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
(_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
(REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
(REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
RE_SYNTAX_POSIX_MINIMAL_BASIC.
(REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
(REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
(REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
(REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
(REG_REALLOCATE): Renamed from REGS_REALLOCATE.
(REG_FIXED): Renamed from REGS_FIXED.
(REG_NREGS): Renamed from RE_NREGS.

(REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
of other REG_* macros, since POSIX says the user is allowed to
#undef these macros selectively.

(reg_errcode_t): Update comment stating what other tables need
to be consistent.

Rename the following enum values to obey POSIX requirements.
The old names are still visible as macros.
(_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
is not defined, since GNU is supposed to be a superset of POSIX as
much as possible, and since we want reg_errcode_t to be a signed
type for implementation consistency.
(_REG_NOERROR): Renamed from REG_NOERROR.
(_REG_NOMATCH): Renamed from REG_NOMATCH.
(_REG_BADPAT): Renamed from REG_BADPAT.
(_REG_ECOLLATE): Renamed from REG_ECOLLATE.
(_REG_ECTYPE): Renamed from REG_ECTYPE.
(_REG_EESCAPE): Renamed from REG_EESCAPE.
(_REG_ESUBREG): Renamed from REG_ESUBREG.
(_REG_EBRACK): Renamed from REG_EBRACK.
(_REG_EPAREN): Renamed from REG_EPAREN.
(_REG_EBRACE): Renamed from REG_EBRACE.
(_REG_BADBR): Renamed from REG_BADBR.
(_REG_ERANGE): Renamed from REG_ERANGE.
(_REG_ESPACE): Renamed from REG_ESPACE.
(_REG_BADRPT): Renamed from REG_BADRPT.
(_REG_EEND): Renamed from REG_EEND.
(_REG_ESIZE): Renamed from REG_ESIZE.
(_REG_ERPAREN): Renamed from REG_ERPAREN.
(REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
(REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
(REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
(REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.

(_REG_RE_NAME, _REG_RM_NAME): New macros.
(REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
changed.  But support the old name if the new one is not defined
and if _REGEX_SOURCE.

Change the following member names in struct re_pattern_buffer.
The old names are still supported if !_REGEX_SOURCE.
The new names are always supported, regardless of _REGEX_SOURCE.
(re_buffer): Renamed from buffer.
(re_allocated): Renamed from allocated.
(re_used): Renamed from used.
(re_syntax): Renamed from syntax.
(re_fastmap): Renamed from fastmap.
(re_translate): Renamed from translate.
(re_can_be_null): Renamed from can_be_null.
(re_regs_allocated): Renamed from regs_allocated.
(re_fastmap_accurate): Renamed from fastmap_accurate.
(re_no_sub): Renamed from no_sub.
(re_not_bol): Renamed from not_bol.
(re_not_eol): Renamed from not_eol.
(re_newline_anchor): Renamed from newline_anchor.

Change the following member names in struct re_registers.
The old names are still supported if !_REGEX_SOURCE.
The new names are always supported, regardless of _REGEX_SOURCE.
(rm_num_regs): Renamed from num_regs.
(rm_start): Renamed from start.
(rm_end): Renamed from end.

(re_set_syntax, re_compile_pattern, re_compile_fastmap):
(re_search, re_search_2, re_match, re_match_2, re_set_registers):
Prepend __ to parameter names.

18 years ago(File descriptor based Input/Output): Add fcntl-safer.
Jim Meyering [Wed, 24 Aug 2005 19:44:08 +0000 (19:44 +0000)]
(File descriptor based Input/Output): Add fcntl-safer.

18 years ago(Depends-on): Add fcntl-safer.
Jim Meyering [Wed, 24 Aug 2005 19:43:48 +0000 (19:43 +0000)]
(Depends-on): Add fcntl-safer.

18 years ago*** empty log message ***
Jim Meyering [Wed, 24 Aug 2005 19:42:04 +0000 (19:42 +0000)]
*** empty log message ***

18 years agoSync from coreutils.
Jim Meyering [Wed, 24 Aug 2005 19:40:42 +0000 (19:40 +0000)]
Sync from coreutils.
New file.

18 years agofilter through indent
Jim Meyering [Wed, 24 Aug 2005 11:56:36 +0000 (11:56 +0000)]
filter through indent

18 years agoAdd multiple-inclusion guard.
Bruno Haible [Wed, 24 Aug 2005 11:04:19 +0000 (11:04 +0000)]
Add multiple-inclusion guard.

18 years agoUse GNU coding style.
Bruno Haible [Wed, 24 Aug 2005 11:01:01 +0000 (11:01 +0000)]
Use GNU coding style.

18 years agoInclude config.h too.
Simon Josefsson [Wed, 24 Aug 2005 10:59:57 +0000 (10:59 +0000)]
Include config.h too.

18 years ago* tests/test-getpass.c: New file.
Simon Josefsson [Wed, 24 Aug 2005 09:21:10 +0000 (09:21 +0000)]
* tests/test-getpass.c: New file.

18 years ago*** empty log message ***
Jim Meyering [Wed, 24 Aug 2005 06:23:16 +0000 (06:23 +0000)]
*** empty log message ***

18 years ago(Makefile.am): Remove `lib_SOURCES += ...' line,
Jim Meyering [Wed, 24 Aug 2005 06:23:07 +0000 (06:23 +0000)]
(Makefile.am): Remove `lib_SOURCES += ...' line,
now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.

18 years agoUse AC_LIBSOURCES and AC_LIBOBJ to indicate source
Jim Meyering [Wed, 24 Aug 2005 06:21:29 +0000 (06:21 +0000)]
Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
and object files for this module.

18 years ago* config/srclist.txt: Add glibc bug 1233.
Paul Eggert [Tue, 23 Aug 2005 20:37:24 +0000 (20:37 +0000)]
* config/srclist.txt: Add glibc bug 1233.
* lib/regex.h (REG_NOSYS)
[!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
Define, since POSIX requires it as of 2001.
(_REG_ENOSYS) [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
New private symbol, used to keep the enum signed in all cases.

18 years ago* config/srclist.txt: Add glibc bug 1232.
Paul Eggert [Tue, 23 Aug 2005 19:11:45 +0000 (19:11 +0000)]
* config/srclist.txt: Add glibc bug 1232.
* lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James Youngman
in <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.

18 years ago* config/srclist.txt: Add glibc bug 1231.
Paul Eggert [Tue, 23 Aug 2005 18:55:44 +0000 (18:55 +0000)]
* config/srclist.txt: Add glibc bug 1231.
* lib/regex_internal.c (re_string_skip_chars, register_state):
(calc_state_hash):
Remove forward decls; no longer needed now that we use prototypes.
* lib/regexec.c (acquire_init_state_context, check_halt_node_context):
(proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
(clean_state_log_if_needed): Likewise.

18 years ago* regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
Paul Eggert [Tue, 23 Aug 2005 18:48:31 +0000 (18:48 +0000)]
* regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
All contents moved to gl_REGEX.
(gl_REGEX): Don't bother checking whether lib/regex.c exists;
assume that it does.

18 years ago* config/srclist.txt: Add glibc bug 1227.
Paul Eggert [Sun, 21 Aug 2005 05:01:20 +0000 (05:01 +0000)]
* config/srclist.txt: Add glibc bug 1227.
* lib/regexec.c (sift_states_bkref): Fix portability bug: the code
assumed that reg_errcode_t is a signed type, which is not
necessarily true if _XOPEN_SOURCE is not defined.

18 years ago* config/srclist.txt: Add glibc bug 1226.
Paul Eggert [Sun, 21 Aug 2005 03:31:45 +0000 (03:31 +0000)]
* config/srclist.txt: Add glibc bug 1226.
* lib/regex_internal.c (calc_state_hash): Put 'inline' before type, since
some compilers warn about it otherwise.

18 years ago* m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
Paul Eggert [Sun, 21 Aug 2005 00:51:27 +0000 (00:51 +0000)]
* m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.

18 years ago* config/srclist.txt: Add glibc bug 1225.
Paul Eggert [Sun, 21 Aug 2005 00:43:34 +0000 (00:43 +0000)]
* config/srclist.txt: Add glibc bug 1225.
* lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
of unused local, dfa.

18 years ago* config/srclist.txt: Add glibc bug 1224.
Paul Eggert [Sun, 21 Aug 2005 00:29:47 +0000 (00:29 +0000)]
* config/srclist.txt: Add glibc bug 1224.
* lib/regcomp.c:
(init_word_char, create_initial_state, duplicate_node_closure):
(fetch_token, peek_token_bracket, build_range_exp):
(build_collating_symbol): Remove forward decls; no longer needed
now that we use prototypes.

18 years ago* config/srclist.txt: Add glibc bug 1223.
Paul Eggert [Sat, 20 Aug 2005 22:26:51 +0000 (22:26 +0000)]
* config/srclist.txt: Add glibc bug 1223.
* lib/regcomp.c (create_initial_state): Remove duplicate decl.

18 years ago* config/srclist.txt: Add glibc bugs 1220, 1221, 1222.
Paul Eggert [Sat, 20 Aug 2005 07:42:15 +0000 (07:42 +0000)]
* config/srclist.txt: Add glibc bugs 1220, 1221, 1222.

* lib/regcomp.c:
(re_compile_pattern, re_set_syntax, re_compile_fastmap):
(re_compile_fastmap_iter, regcomp, regerror, regfree):
(re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
(create_initial_state, optimize_utf8, analyze, postorder, preorder):
(optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
(link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
(duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
(fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
(parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
(build_range_exp, build_collating_symbol, parse_bracket_exp):
(parse_bracket_element, parse_bracket_symbol, build_equiv_class):
(build_charclass, build_charclass_op, fetch_number, create_tree):
(create_token_tree, mark_opt_subexp, duplicate_tree):
Use prototypes rather than old-style definitions.
* lib/regex_internal.c:
(re_string_allocate, re_string_construct, re_string_realloc_buffers):
(re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
(re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
(re_string_reconstruct, re_string_peek_byte_case):
(re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
(re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
(re_node_set_init_copy, re_node_set_add_intersect):
(re_node_set_init_union, re_node_set_merge, re_node_set_insert):
(re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
(re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
(re_acquire_state, re_acquire_state_context, register_state):
(create_ci_newstate, create_cd_newstate, free_state):
Likewise.
* lib/regexec.c (regexec, re_match, re_search, re_match_2, re_search_2):
(re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
(re_search_internal, prune_impossible_nodes):
(acquire_init_state_context, check_matching, static):
(check_halt_node_context, check_halt_state_context, proceed_next_node):
(push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
(update_regs, sift_states_backward, build_sifted_states):
(clean_state_log_if_needed, merge_state_array):
(update_cur_sifted_state, add_epsilon_src_nodes):
(sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
(check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
(sift_states_iter_mb, transit_state, merge_state_with_log, static):
(find_recover_state, check_subexp_matching_top, transit_state_mb):
(transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
(check_arrival, check_arrival_add_next_nodes):
(check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
(expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
(check_node_accept_bytes, check_node_accept, extend_buffers):
(match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
(search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
(sift_ctx_init):
Likewise.

* lib/regex_internal.h:
(re_string_allocate, re_string_construct, re_string_reconstruct):
(re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
(build_upper_buffer, re_string_translate_buffer, re_string_destruct):
(re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
(re_string_context_at, re_string_peek_byte_case):
(re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
is defined, since we now use prototypes always.

* lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
C89 or better.  All uses removed.

18 years agoRecent regex patches.
Paul Eggert [Sat, 20 Aug 2005 01:03:31 +0000 (01:03 +0000)]
Recent regex patches.

18 years agoAdd glibc bug 1218.
Paul Eggert [Sat, 20 Aug 2005 01:03:17 +0000 (01:03 +0000)]
Add glibc bug 1218.

18 years ago(re_acquire_state, re_acquire_state_context) [defined lint]:
Paul Eggert [Sat, 20 Aug 2005 00:58:13 +0000 (00:58 +0000)]
(re_acquire_state, re_acquire_state_context) [defined lint]:
Suppress bogus uninitialized-variable warnings.

18 years agoAdd glibc bug 1217 for regcomp.c.
Paul Eggert [Sat, 20 Aug 2005 00:07:54 +0000 (00:07 +0000)]
Add glibc bug 1217 for regcomp.c.