To figure out whether there's been diffs or not, the sentinel function
    checks whether the resulting buffer is empty.

I think that is a mistake.  The reliable way for it to tell
whether there are differences is to look at the exit status from diff.

    Given his description of the problem, my guess is that somehow the sentinel
    is run before all the process's output has been processed.

That can happen.  Two different signals indicate (1) the process is dead
and (2) there is output.  I think they can arrive in any order.
Does anyone know for certain?

Also, wait_reading_process_output runs sentinels before it
reads output.  So if the signals arrive at the same time,
Emacs will run the sentinel first.  That is arguably a bug,
but I think it is really risky to change that.

I will document this.


_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

Reply via email to