On Thu, Jun 16, 2011 at 02:53:41PM +0100, Nuno Lucas wrote: > On 06/16/2011 05:51 AM, Timo Teräs wrote: > >Notably, though, at least sed.c seems to rely on the fact that \n and \0 > >are both recognized, and jumps through many hoops to handle them both > >properly. Apparently there's out some sed scripts that use both \n and > >\0 as statement separator, but they have different meaning. > > > >Not sure if there's other applets relying on this. > > > >But just like I told before, this also reason why the API needs rewrite, > >it should *not* treat both as line separators, unless there's some > >explicit need. > > See, e.g, the -print0 parameter in "find". > [...]
A program that's parsing "-print0 format" data must interpret *only* null bytes as delimiters, not both null bytes and newlines. I can't see how it would ever be useful to interpret both, and if busybox is currently interpreting both in some places, that sounds like a bug due to laziness... Rich _______________________________________________ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox