diff options
author | Glenn L McGrath <bug1@ihug.co.nz> | 2003-09-14 04:06:12 +0000 |
---|---|---|
committer | Glenn L McGrath <bug1@ihug.co.nz> | 2003-09-14 04:06:12 +0000 |
commit | 8aac05bfe5ffdbc4c9591d7d5b486c0af0769a7a (patch) | |
tree | 19d33618ba3c558cd34ab743fea1a2a52f6949d0 /testsuite/strings/strings-works-like-GNU | |
parent | 7c59a83a779fa9cb92b9d37e462a130c380d14d4 (diff) | |
download | busybox-8aac05bfe5ffdbc4c9591d7d5b486c0af0769a7a.tar.gz |
Patch from Rob Landley
Fixed a memory leak in add_cmd/add_cmd_str by moving the allocation
of sed_cmd down to where it's actually first needed.
In get_address, if index_of_next_unescaped_regexp_delim ever failed, we
wouldn't notice because the return value was added to idx, which was
already guaranteed to be > 0. (This is buried in the changes made when
I redid get_address to be based on pointer arithmetic, because all the tests
were gratuitously dereferencing with a constant zero, which wasn't obvious.)
Comment in parse_regex_delim was wrong: 's' and 'y' both call it.
The reason "sed_cmd->num_backrefs = 0;" isn't needed is that sed_cmd was
allocated with cmalloc, which zeroes memory.
Different handling of space after \ in i...
Different handling of pattern "s/a/b s/c/d"
Cool, resursive reads don't cause a crash. :)
Fixed "sed -f blah filename - < filename" since GNU sed was handling
both - and filenames on the same line. (You can even list - more than
once, although it's immediate EOF...)
Diffstat (limited to 'testsuite/strings/strings-works-like-GNU')
0 files changed, 0 insertions, 0 deletions