diff options
| author | John Wiegley <johnw@newartisans.com> | 2002-04-08 08:33:32 +0000 |
|---|---|---|
| committer | John Wiegley <johnw@newartisans.com> | 2002-04-08 08:33:32 +0000 |
| commit | 110d1880915bf26b13a8309419a67bf272b34d4d (patch) | |
| tree | 8f5febc9dbbe7c84f0a8b1e13eb463f47a3a33cf /chess-engine.el | |
| parent | b0714ff514de8db1c49d48f18b7a8d25e9cf9200 (diff) | |
*** no comment ***
Diffstat (limited to 'chess-engine.el')
| -rw-r--r-- | chess-engine.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/chess-engine.el b/chess-engine.el index 4b6fc4c..eb61b17 100644 --- a/chess-engine.el +++ b/chess-engine.el @@ -143,7 +143,10 @@ (defun chess-engine-send (engine string) (chess-with-current-buffer engine - (process-send-string (get-buffer-process (current-buffer)) string))) + (let ((proc (get-buffer-process (current-buffer)))) + (if (and proc (memq (process-status proc) '(run open))) + (process-send-string proc string) + (error "The engine you are using is no longer running"))))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; |
