[Cvsnt] Editor problem using CVSNT build 57d on Win2K

Anthony Williams anthwil at nortelnetworks.com
Tue Jun 18 10:40:51 BST 2002

Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.

"Tony Hoyle" <tmh at nothing-on.tv> wrote in message
news:3d0e044e.867439656 at news.cvsnt.org...
> On Mon, 17 Jun 2002 14:52:18 +0000 (UTC), "Anthony Williams"
> <anthwil at nortelnetworks.com> wrote:
> >The new version works OK with both gnuclient and vi. Thanks.
> >
> The biggest problem is run_popen which can't use waitpid as its
> listener is in a child process (Unix only lets you wait for your own
> children, which I suppose make some sense).  I think the way I've done
> it now works but it'll need some testing.

You could move the run_command into the child that does the monitoring (so
the execed process is now a grandchild of the original cvs), but then you
would have to do the pipes before the first fork, so the original cvs can
talk to the grandchild process. Messy, but at least you can then monitor the
grandchild properly. You've still got the issue of trapping errors, though.

Anyway, since we only really care about i/o for the target of a popen, and
not whether or not it has finished, your current code looks OK --- if the
output streams are closed at the target end, stop reading them. If the
target is still running, who cares? When we're finished writing to it, we'll
close our end of its stdin. If it then sits around for 3 days chewing the
cud, it doesn't matter.

Anthony Williams
Software Engineer, Nortel Networks Optical Components Ltd
The opinions expressed in this message are not necessarily those of my

Cvsnt mailing list
Cvsnt at cvsnt.org
http://www.cvsnt.org/cgi-bin/mailman/listinfo/cvsnt https://www.march-hare.com/cvspro/en.asp#downcvs

More information about the cvsnt mailing list
Download the latest CVSNT, TortosieCVS, WinCVS etc. for Windows 8 etc.
@CVSNT on Twitter   CVSNT on Facebook