Len Trigg writes:
 > Raul Acevedo wrote:
 > > Would the problem be "solved" if comint returned code 1, instead of 129?
 > > 
 > > In other words, is the problem that comint returns an inappropriate
 > > error code, or that comint returns *any* error code at all (i.e. it
 > > shouldn't get an error from the subprocess in the first place)?
 > 
 > I think the latter. The bug typically bites me when running JUnit
 > tests and it's clear (based on the expected output) that either the
 > process terminates early, or a large part of the output is just lost.
 > 

comint is the Emacs interface to external processes such as jdb or bash. 
It's purpose is to allow Emacs users to interact with external processes,
i.e., to send input to the standard input of the external process and
to view the standard output of the external process. The JDEE uses
comint to allow JDEE users to interact with jdb, the BeanShell, and
other external processes. 

comint writes Emacs user input to the standard input of the external
process and reads from the standard output of the external process and
displays the output in an Emacs buffer. I don't know how comint
handles the error output of an external process.  My assumption has
always been that it reads the standard error output of the external
process and treats it as if it were coming from standard output, i.e.,
it simply passes the standard output to clients of comint as if the
error output were coming from the external process's standard outpuut.

My guess is that some recent versions of comint or Emacs have a bug
in the handler for the standard error output of an external process
that causes the error. Because the JDEE uses comint to interfaces to
external processes, in particular, jdb, this would mean that if jdb
encounters an error condition and tries to communicate the error by
writing a message to its standard error output instead of to its
standard output pipe, this causes the 129 error message on some
versions of Emacs or Linux. I'm not sure that the JDEE can fix
this problem as my suspicion is that the problem is with comint
or with Emacs C functions on which comint relies.

Paul

Reply via email to