[Top][All Lists]

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

Re: patch to support output synchronization under -j

From: Howard Chu
Subject: Re: patch to support output synchronization under -j
Date: Thu, 14 Apr 2011 12:24:38 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:2.0b13pre) Gecko/20110322 Firefox/4.0b13pre SeaMonkey/2.1b2pre

Paul Smith wrote:
On Thu, 2011-04-14 at 14:08 -0400, David Boyce wrote:
Of course, either way some context is lost. If you put both into one
temp file you lose track of which was which; if you keep them in
separate files you lose ordering instead. So it becomes a matter of
taste, or perhaps an option though that seems like a bit too much to

I agree that adding an option seems like a lot.

I think it's more important to maintain ordering of stdout/stderr than
it is to allow individual redirection.

However, you could do both with some heuristics.  Hm.  Maybe not.  I was
going to say you could merge them if stdout and stderr were going to the
same tty or file, but I don't think there's any good way in UNIX to know
whether two file descriptors are pointing at the same file/device.  Hrm.
In Linux you can find out via /proc but that's a pretty special case.

You wouldn't just use fstat() and compare dev and ino numbers?

  -- Howard Chu
  CTO, Symas Corp.           http://www.symas.com
  Director, Highland Sun     http://highlandsun.com/hyc/
  Chief Architect, OpenLDAP  http://www.openldap.org/project/

reply via email to

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