bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#1082: 23.0.60; read-char unexpectedly halts execution of script


From: Markus Triska
Subject: bug#1082: 23.0.60; read-char unexpectedly halts execution of script
Date: Tue, 07 Oct 2008 00:17:02 +0200

Andreas Schwab <schwab@suse.de> writes:

> In non-interactive mode we always want restartable syscalls, since
> keyboard input goes through stdio (SYNC_INPUT makes no difference here).
> I've checked in a fix.

Thank you, it fixes this problem for me. Could process output also be
handled, as in interactive use? E.g., M-x eval-region on the forms:

   (defun bc-filter (proc string)
     (message "%s" string))

   (message "starting")
   (setq bc (start-process "bc" nil "/usr/bin/bc"))
   (set-process-filter bc 'bc-filter)

   (while t
     (let ((char (read-char nil nil 0.1)))
       (when char
         (message "char: %s" char))))

processes the output of bc, and shows:

   starting
   bc 1.06
   Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
   This is free software with ABSOLUTELY NO WARRANTY.
   For details type `warranty'.

Whereas in "emacs --script" mode, this output is not shown.






reply via email to

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