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

Re: dwww: cat and file (pipe race condition)



Hi,

Andrew Pimlott wrote:

> I just read this one message so I don't know what the original
> problem is.  However, I think you are misdiagnosing or misexplaining
> this.  The SIGPIPE goes to and only to $process.  The reason is that
> file closes its stdin as soon as it has ready a few bytes, with the
> result that $process then has nowhere to write.  cat cannot get a
> SIGPIPE because it is writing to /dev/null, which rarely stops
> accepting bits.

I sent the original message to debian-devel.

I am not the maintainer of any of the mentioned packages, but a user
who faced the web server timeout.  I'll send you the original message
separately. Maybe you have an new idea.  FWIW, the behaviour of the web server
differs slightly, depending on what shell actually is /bin/sh. If /bin/sh
is ash, the web server suffers a timeout. If /bin/sh is bash, for those
mentioned links in 8 out of 10 cases, the file is read but not rendered (it
is HTML), instead it is displayed as HTML source. The remaining 2 cases are
shown correctly in bash.

Unfortunately, I'm not sure what this means. I reported a bug (#61452)
against ash, but I'm not quite so certain anymore.

  Ulf

P.S. You might want to try (if you use dwww, that is) on your local
     system the documentation of the Debian Menu Guide, Chapter 3 and
     6. Interesting for me was, that file reads more data than those
     files contain! (If I haven't misunderstood the source).
     I could confirm this problem with both boa and apache.


Reply to: