groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] grohtml - "too many open files"


From: Ralph Corderoy
Subject: Re: [Groff] grohtml - "too many open files"
Date: Fri, 01 Dec 2006 15:40:43 +0000

Hi again Larry,

> What status close() returns depends on your awk.  And closing a pipe
> should wait for the command to finish so if you've a grep that
> produces 1E6 lines and you just want to read the first then pipe it
> into `sed 1q' before reading it into awk so the grep gets a SIGPIPE on
> writing to the finished sed, curtailing its largess.

Thinking about it some more.  As long as your command does the default
thing of dying on SIGPIPE you don't need to worry about curtailing its
output since close() in awk will deliver a SIGPIPE to the writer when it
next attempts to write(2).  I must have had something in the past that
either blocked SIGPIPE or did something else strange that meant I had to
mess around in this way.

Cheers,


Ralph.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]