"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Tracey Emery <tracey@traceyemery.net>
Subject:
Re: fix merge bug with dot on a line by itself
To:
gameoftrees@openbsd.org
Date:
Mon, 11 Oct 2021 08:05:51 -0600

Download raw body.

Thread
On Mon, Oct 11, 2021 at 11:12:10AM +0200, Stefan Sperling wrote:
> On Fri, Oct 08, 2021 at 10:21:26PM +0200, Stefan Sperling wrote:
> > Another way of "fixing" the issue without a major rewrite is to read
> > data from input files in units of lines rather than BUFSIZ chunks.
> > We can then prepend a symbol of our choice (other than a dot) before
> > each line which represents content that is supposed to appear in the
> > merged output. Now all content is "escaped" and will never result in a
> > dot on a line by itself that can be mistaken as a delimiter. We strip
> > our leading symbol before writing a line of content out.
> 
> Does anybody have a better idea, or should I go ahead with this hack?

Ok. This workaround is fine for me, until a better solution is
introduced. I don't have any other ideas. Anyone else?

-- 

Tracey Emery