[patch] sed replace bb_get_chunk_from_file
Rob Landley
rob at landley.net
Thu May 18 20:12:22 UTC 2006
On Wednesday 17 May 2006 10:44 pm, Rich Felker wrote:
> > And the reason I have these in the todo heap is that I've got half a
> > rewrite of sed to make it _properly_ handle embedded nul bytes (which
> > requires changing the entire codepath to take buffer+length rather than a
> > nul terminated buffer.)
>
> BTW how does one do this without a custom version of regex? Is there
> some trick for replacing characters to make it work?
Iterating over the regex sections, which is presumably the same way the gnu
version does it.
And there's two cases: the regex has embedded nuls and the string to search
has embedded NULs, and I put test cases for both of those in sed.tests...
> Rich
Rob
--
Never bet against the cheap plastic solution.
More information about the busybox
mailing list