| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
const promise when processing it in the regex engine.
Minor tweak and OK schwarze@
|
|
|
|
|
|
|
| |
or prototypes. Ditto for some of the char* and void* casts too.
verified no change to instructions on ILP32 (i386) and LP64 (amd64)
ok natano@ abluhm@ deraadt@ millert@
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The new code sees this combination as a continuation of string at offset
pmatch[0].rm_so, instead of a new string which starts at that offset.
This change fixes a search quirk in vi and is needed for upcoming fixes in
ed/sed/vi.
This new behaviour is also used in gnu regex.
Lots of help from schwarze@
Manpage bits by schwarze@
OK schwarze@ and millert@
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change touches code that only runs when REG_BASIC is given and the
regular expression is anchored with [[:<:]] or \< _and_ uses backreferences.
Simplify the logic while here, already looking at the previous character
if REG_STARTEND and REG_NOTBOL are both in use, in anticipation of
martijn@'s upcoming patch which will further improve REG_STARTEND.
OK millert@ martijn@
Also tested by Pedro Giffuni (pfg) on FreeBSD.
|
|
|
|
|
|
|
|
|
|
| |
This change touches code that only runs when REG_BASIC is given and
the regular expression is anchored with ^ _and_ uses backreferences.
The segfault could only be triggered when the ^ anchor was inside
a leading () subexpression quantified with *.
OK martijn@
Patch also proofread by Pedro Giffuni <pfg at FreeBSD dot org>.
|
|
|
|
| |
ok tb@
|
|
|
|
|
| |
proper mult int overflow detection. The existing code already handles
malloc failure properly, of course.
|
|
|
|
|
|
|
|
|
|
| |
OUT to EOW, making its domain CHAR_MIN...CODEMAX. It makes sense to have
pchar() take the same domain and output those non-characters appropriately,
so the (unsigned char) cast for isprint() goes in pchar(). Constipate
pchar() while we're here, and let print() pass through NUL to it, as it
knows how to output it unambiguously.
ok otto@ millert@
|
|
|
|
| |
appropriate. in regex, stop using the struct hack for a fixed size array
|
| |
|
|
|
|
|
|
| |
run out of mem! From FreeBSD PR 75656.
ok millert@ deraadt@
|
|
|
|
| |
parameter names from prototypes. ok millert@
|
|
|
|
|
|
|
|
| |
\(b*\)\(a*\1\)*, more cases in regress/lib/libc/regexp/test.
Only stop evaluation of a back reference if the match lenght is
zero and the recursion level is too deep. With help from jaredy@
Problem case found by Andrew Brown in NetBSD PR 28126.
ok deraadt@ millert@
|
| |
|
|
|
|
| |
dump found by jmc@. OK otto@
|
|
|
|
|
|
|
| |
For example:
echo "foo foo bar bar bar baz" | sed 's/\([^ ]*\)\( *\1\)*/\1/g'
Test case found by dhartmei@
ok millert@ dhartmei@ tedu@
|
|
|
|
| |
From NetBSD.
|
|
|
|
| |
rescinded 22 July 1999. Proofed by myself and Theo.
|
| |
|
| |
|
|
|
|
|
|
| |
- move an assert to be *before* a strcpy() where it can do some good.
- integrate NetBSD fixes for 64-bit machines (NetBSD PR #3450, Ross Harvey)
- add lite2 tags
|
| |
|
|
|
|
| |
Make sure everything uses {SYS,}LIBC_SCCS properly
|
|
|