Thayne Harbaugh <[EMAIL PROTECTED]> writes:

> "Niels M�ller" wrote:
>
> > As far as I can see from the source, the file should
> > be opened in O_APPEND mode.
> 
> Funny.  It never appends for me - it always overwrites the old file.
> The plot thickens . . .

If so, the extra data is most likely previous contents of the file.

> > It would be interesting to find out how lsh writes the data. Do you
> > think you can truss it when this happens, and give me the information
> > calls for the right fd?
> 
> I'm not sure I understand what you mean here.

Use truss (or strace, the name of that program varies) to find out
exactly how open() is called on the file (to see if the O_APPEND flag
is included), and the write() calls to see exactly what lsh writes to
it.

/Niels

Reply via email to