From 9066275509f32818e75d8109aafd43c57847c05c Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 11 Apr 2006 00:52:16 +0000 Subject: Adjust to new regex.h API (with new fastmap type), and clean up the regex storage allocation a bit. --- ChangeLog | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 2dbb0cca3..0e42763bc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,38 @@ -2006-03-30 Jim Meyering +2006-04-10 Paul Eggert * Version 6.0-cvs. + Adjust to new regex.h API (with new fastmap type), and clean + up the regex storage allocation a bit. + + * src/csplit.c (struct control): Put re_compiled member at the + end, since it's large. Change regexpr member from char * to bool; + all uses changed. Add new member fastmap. + (extract_regexp): regexp arg is now char const *, not char *. + Don't bother duplicating the regular expression; it's not needed. + Set fastmap from new fastmap member. Don't bother allocating + a buffer, as the regexp code does a better job than we do. + * src/expr.c (docolon): Allocate and use a fastmap. + Don't bother allocating a buffer. + * src/nl.c (body_fastmap, header_fastmap, footer_fastmap): + New vars. + (build_type_arg): New fastmap arg. All uses changed. + Don't bother allocating a buffer, but set a fastmap. + * src/ptx.c (context_regex_string, word_regex_string): Remove. + (context_regex, word_regex): New vars, replacing the above. + All uses changed. + (struct regex_data): New type. + (compile_regex): Renamed from alloc_and_compile_regex, since + we no longer allocate storage. Arg is now a struct regex_data *, + not a const char *. All uses changed. Don't allocate the fastmap; + instead, take it from the caller. Don't convert size_t to int, + to avoid arithmetic overflow problems. Don't bother freeing + storage afterwards; it's not worth the aggravation. + * src/tac.c (compiled_separator_fastmap): New ver. + (main): Use it. Don't bother allocating a buffer. + +2006-03-30 Jim Meyering + * src/dd.c (iwrite): Remove assignment without effect. Reported by Felix Rauch Valenti. -- cgit v1.2.3-70-g09d2