80 Commits
Author SHA1 Message Date
Paolo Bonzini cba6413f07 finish gnulib conversion -- upgrade bootstrap and a few details
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-79
v4.1a
2008-01-09 16:12:16 +01:00
Paolo Bonzini ef5850a7c8 gnulib works!
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-78
2008-01-09 16:12:16 +01:00
Paolo Bonzini ea914e33ea always set LINGUAS, even if --skip-po
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-77
2008-01-09 16:12:15 +01:00
Paolo Bonzini 59ee990c6b gnulibify part 2, use gnulib-tool in autoboot and remove PO files from repo
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-76
2008-01-09 16:12:14 +01:00
Paolo Bonzini e2fe13c4f8 gnulib .gitignore files 2008-01-09 16:12:14 +01:00
Paolo Bonzini ac9a20b3fb gnulibify and add ACL support
2006-09-24  Paolo Bonzini  <bonzini@gnu.org>

	* sed/execute.c: Support ACLs.
	* lib/utils.c: Move...
	* sed/utils.c: ... here, and remove xmalloc.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-74
2008-01-09 16:12:13 +01:00
Paolo Bonzini 0177318fa6 accept NUL for `.'
2006-08-21  Paolo Bonzini  <bonzini@gnu.org>

	* sed/regexp.c: Accept NUL bytes for `.'.  Accept 'a\(b' in
	POSIXLY_CORRECT/POSIXLY_BASIC posixicity.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-73
2008-01-09 16:12:12 +01:00
Paolo Bonzini b8eb0a13d4 fix cygwin binary mounts
2006-08-03  Paolo Bonzini  <bonzini@gnu.org>

	Revert this part of the previous change:

	2006-08-03  Paolo Bonzini  <bonzini@gnu.org>

	* sed/compile.c (get_openfile): Change second argument to char
	and turn it into a string within the function.  Adjust callers.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-72
2008-01-09 16:12:11 +01:00
Paolo Bonzini 3a8e165ab0 treat cygwin CR/LF correctly (and by design, not by chance)
2006-08-03  Paolo Bonzini  <bonzini@gnu.org>
            Corinna Vinschen  <vinschen@redhat.com>

        * lib/getline.c (getline): Remove Windows special casing.
        * lib/utils.c (register_open_file, ck_fdopen): New.
        (ck_fopen, ck_mkstemp): Use register_open_file.
        * lib/utils.h (ck_fdopen): New.
        * sed/execute.c (open_next_file): Reopen stdin.
        * sed/sed.h (read_mode): New.
        * sed/sed.c (read_mode): New.
        (main): Set it on --binary.
        (usage): Document --binary.
        * sed/compile.c (get_openfile): Change second argument to char
        and turn it into a string within the function.  Adjust callers.
        * sed/execute.c (dump_append_queue, open_next_file): Use it
        as mode for ck_fopen.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-71
2008-01-09 16:12:11 +01:00
Paolo Bonzini 3ca529fbe2 hack to speed up UTF-8 processing
2006-08-03  Paolo Bonzini  <bonzini@gnu.org>

	* sed/execute.c (str_append): Use is_utf8 to skip useless work.
	* sed/mbcs.c (initialize_mbcs): Look for a UTF-8 locale.
	(is_utf8): New.
	* sed/sed.h (is_utf8): New.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-70
2008-01-09 16:12:10 +01:00
Paolo Bonzini 4ca34ac568 don't rely on malloc(0) != NULL
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-69
2008-01-09 16:12:09 +01:00
Paolo Bonzini ec9561cfa4 robustify bootstrap process, ensure distribution of updated boostrap.sh
2006-07-13  Paolo Bonzini  <bonzini@gnu.org>

	* bootstrap.sh.in: Add a few autoconfy tests.
	* Makefile.am: Update distributed bootstrap.sh.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-68
2008-01-09 16:12:08 +01:00
Paolo Bonzini 760bf669e6 do not mention Estonian locale in BUGS
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-67
2008-01-09 16:12:08 +01:00
Paolo Bonzini 3cfe7fdf8a Fix compilation on non-GCC compilers, update po files
2006-05-15  Hans-Bernhard Bröker <broeker@physik.rwth-aachen.de>

	* sed/basicdefs.h (OB_MALLOC): Turn VCAST into void * cast.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-66
2008-01-09 16:12:07 +01:00
Paolo Bonzini 6ed57b0429 document that sed -i breaks links
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-65
2008-01-09 16:12:06 +01:00
Paolo Bonzini 034190bd22 fix for freebsd sed
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-64
2008-01-09 16:12:05 +01:00
Paolo Bonzini 44536f208a bump version number to 4.1.5
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-63
v4.1.5
2008-01-09 16:12:04 +01:00
Paolo Bonzini 1ca31d6728 fix y/[/X/ and add more testcases for the y command
2006-02-03  Paolo Bonzini  <bonzini@gnu.org>

	* sed/compile.c (compile_program) <case 'y'>: Pass false to match_slash.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-62
2008-01-09 16:12:04 +01:00
Paolo Bonzini ef1ea7f8bb add install_sh definition to intl/po
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-61
2008-01-09 16:12:03 +01:00
Paolo Bonzini de400b3b34 fix `turn filenames into lowercase' example
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-60
2008-01-09 16:12:02 +01:00
Paolo Bonzini 811c3446c6 merge with glibc regex
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-59
2008-01-09 16:12:01 +01:00
Paolo Bonzini a8485beddc fix sed faq address
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-58
2008-01-09 16:12:00 +01:00
Paolo Bonzini 6cf9fe5b1b add LANG_SORBIAN and other mingw fixes
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-57
2008-01-09 16:11:59 +01:00
Paolo Bonzini 6d02437ad8 fix typo in docs/Makefile.am
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-56
2008-01-09 16:11:58 +01:00
Paolo Bonzini 34b6da2799 remove RCS markers
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-55
2008-01-09 16:11:58 +01:00
Paolo Bonzini 912c1770ac update regex from upstream
2005-09-07  Paolo Bonzini  <bonzini@gnu.org>

	* lib/regcomp.c: Update from upstream.
	* lib/regex.c: Update from upstream.
	* lib/regex_.h: Update from upstream.
	* lib/regex_internal.c: Update from upstream.
	* lib/regex_internal.h: Update from upstream.
	* lib/regexec.c: Update from upstream.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-54
2008-01-09 16:11:57 +01:00
Paolo Bonzini d6bda34b13 provide a better name for the man page
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-53
2008-01-09 16:11:56 +01:00
Paolo Bonzini 9015803ab0 fix 0~2, signaled by Guglielmo Bondioni
2005-08-30  Paolo Bonzini  <bonzini@gnu.org>

	* sed/execute.c (reset_addresses): Never activate ADDR_IS_NUM_MOD
	addresses.
	* testsuite/modulo.good, testsuite/modulo.inp, testsuite/modulo.sed:
	New.
	* testsuite/Makefile.tests: Add new testcase.
	* testsuite/Makefile.am: Add new testcase.
	* testsuite/Makefile.in: Regenerate.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-52
2008-01-09 16:11:55 +01:00
Paolo Bonzini bdbfe6d711 merge regex with glibc and adjust doc/.arch-inventory
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-51
2008-01-09 16:11:54 +01:00
Paolo Bonzini 584e5cedc2 more updates to the FSF address
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-50
2008-01-09 16:11:53 +01:00
Paolo Bonzini 07e543c45f update FSF address
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-49
2008-01-09 16:11:52 +01:00
Paolo Bonzini 72edd0eea0 add cache variable for -lcP test
2005-05-18  Maciej W. Rozycki  <macro@linux-mips.org>

	* configure.ac: Use a cache variable for the libcP test.
	* configure: Regenerate.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-48
2008-01-09 16:11:51 +01:00
Paolo Bonzini d3f8e118d5 fix handling of [^]xyz]
2005-05-16  Eero Hakkinen  <eero17@bigfoot.com>

	* sed/compile.c (snarf_char_class): Fix handling of
	[^]xyz].

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-47
2008-01-09 16:11:51 +01:00
Paolo Bonzini 480bc129c1 update PO files from translation project
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-46
2008-01-09 16:11:50 +01:00
Paolo Bonzini f7eed06223 do not add a default command-line in in-place editing mode
2005-04-11  Paolo Bonzini  <bonzini@gnu.org>

	* sed/execute.c (process_files): Do not add a default
	command-line in in-place editing mode.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-45
2008-01-09 16:11:49 +01:00
Paolo Bonzini 479184e226 fix a/r/R commands when q is encountered
2005-02-10  Paolo Bonzini  <bonzini@gnu.org>

	* testsuite/appquit.good, testsuite/appquit.inp,
	testsuite/appquit.sed: New testcase.
	* testsuite/readin.sed: Quit after the last r command.
	* testsuite/readin.good: Adjust.
	* sed/execute.c (execute_program): Dump the results of the
	a/r/R commands just before quitting.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-44
2008-01-09 16:11:49 +01:00
Paolo Bonzini 20a67b75e7 fix crash on /\(\)/x
2005-02-10  Paolo Bonzini  <bonzini@gnu.org>

	* lib/regcomp.c (lower_subexp): Do not optimize empty
	subexpressions even with REG_NOSUB.
	* testsuite/SPENCER.tests: Add a previously failing testcase.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-43
2008-01-09 16:11:48 +01:00
Paolo Bonzini 93f1e336c3 fix debian bug 294339
2005-02-10  Paolo Bonzini  <bonzini@gnu.org>

	* sed/regexp.c: Fix off-by-one error in the "invalid reference
	to subexpression" message.  Debian bug 294339.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-42
2008-01-09 16:11:47 +01:00
Paolo Bonzini cf7d4aadd2 include config.h from within obstack.h
2005-02-08  Paolo Bonzini  <bonzini@gnu.org>

	* lib/obstack.h: include config.h.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-41
2008-01-09 16:11:46 +01:00
Paolo Bonzini a790e364e0 add Ulrich Drepper to the THANKS file
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-40
2008-01-09 16:11:46 +01:00
Paolo Bonzini 911678b24e make --enable-html enable building .html files, not just installing
2005-02-01  Paolo Bonzini  <bonzini@gnu.org>

	* doc/Makefile.am: Don't enable MAKEINFO_HTML and TEXI2HTML_HTML
	rules unless BUILD_HTML.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-39
2008-01-09 16:11:45 +01:00
Paolo Bonzini 5b8a413620 finally resync with glibc
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-38
2008-01-09 16:11:44 +01:00
Paolo Bonzini f6330a3c93 finishing touches :-) for 4.1.4
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-37
2008-01-09 16:11:43 +01:00
Paolo Bonzini 87cdf72890 fix meaning of \B
2005-01-26  Paolo Bonzini  <bonzini@gnu.org>

	* posix/regcomp.c (peek_token): Fix ctx_type for \B.
	(parse_expression): Lower token->opr.ctx_type == NOT_WORD_DELIM.
 	* posix/regex_internal.h (re_context_type): Add NOT_WORD_DELIM
	and OUTSIDE_WORD.
	* posix/PCRE.tests: Adjust \B tests to check if it matches outside
	a word.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-36
2008-01-09 16:11:43 +01:00
Paolo Bonzini b48e80e8ad prepare for 4.1.4 release
2005-01-25  Paolo Bonzini  <bonzini@gnu.org>

	* sed/regexp.c: Fix building on GCC 2.95 and earlier.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-35
2008-01-09 16:11:42 +01:00
Paolo Bonzini 32cf31f2ba compute inveclosure only if actually needed.
2004-12-31  Paolo Bonzini  <bonzini@gnu.org>

	* regcomp.c (calc_inveclosure): Return reg_errcode_t.
	Initialize the node sets in dfa->inveclosures.
	(analyze): Initialize inveclosures only if it is needed.
	Check errors from calc_inveclosure.
	* regex_internal.c (re_dfa_add_node): Do not initialize
	the inveclosure node set.
	* regexec.c (re_search_internal): If nmatch includes unused
	subexpressions, reset them to { rm_so: -1, rm_eo: -1 } here.
	Limit to preg->re_nsubs the nmatch that is passed to set_regs.
	(set_regs): Remove the real_nmatch variable, the nmatch
	parameter now is <= preg->re_nsubs.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-34
2008-01-09 16:11:41 +01:00
Paolo Bonzini 5135bf4814 do not use leftmost-longest matching for addresses.
2004-12-26  Paolo Bonzini  <bonzini@gnu.org>

	Do not use leftmost-longest matching for addresses.

	* NEWS: Add a note about this.
	* testsuite/recall2.good, testsuite/recall2.inp,
	testsuite/recall2.sed: New test.
	* testsuite/Makefile.am, testsuite/Makefile.tests: Add the
	recall2 test.
	* sed/sed.h (struct regex): New.
	(struct addr, struct subst, compile_regex, match_regex,
	release_regex): Use it instead of regex_t.
	* sed/compile.c (compile_program): Update for new meaning of
	the third parameter of compile_regex.
	* sed/execute.c (do_subst): Pass less conservative value to
	the regsize parameter of match_regex.
	* sed/regexp.c (compile_regex_1): New, extracted out of
	compile_regex.  The third parameter, needed_sub, now includes
	\0 (so 10 means that \0 .. \9 are needed).  Pass RE_NO_SUB
	if needed_sub is zero.
	(compile_regex): Accept a struct regex instead of a regex_t.
	Save the regular expression's text.
	(match_regex): Accept a struct regex instead of a regex_t.
	Recompile the pattern if it was compiled with RE_NO_SUB.
	(release_regex): Accept a struct regex instead of a regex_t.

	* doc/Makefile.am: Generate sed.texi correctly when
	building outside srcdir.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-33
2008-01-09 16:11:40 +01:00
Paolo Bonzini 84342a5b93 commit autogenerated sed.texi.
git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-32
2008-01-09 16:11:40 +01:00
Paolo Bonzini bc7f50307a warn against localization issues
2004-12-26  Paolo Bonzini  <bonzini@gnu.org>

	* BUGS: Add section about [a-z] matching uppercase characters,
	and other locale issues.
	* doc/sed-in.texi [!PERL]: Likewise.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-31
2008-01-09 16:11:39 +01:00
Paolo Bonzini 65048613e4 speed up transit_state_mb
2004-12-27  Paolo Bonzini  <bonzini@gnu.org>

	* lib/regexec.c (transit_state_mb): Do not examine nodes where
	the ACCEPT_MB is not set.

git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-30
2008-01-09 16:11:38 +01:00