diff options
Diffstat (limited to 'scsh-process.scm')
-rw-r--r-- | scsh-process.scm | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/scsh-process.scm b/scsh-process.scm index 60b9fab..88404a9 100644 --- a/scsh-process.scm +++ b/scsh-process.scm @@ -11,7 +11,7 @@ ;; WARNING: Don't mix with threading unless you're using ;; Chicken 4.8.1 rev 47b5be71 or later. ;; -;;; Copyright (c) 2012-2017, Peter Bex +;;; Copyright (c) 2012-2018, Peter Bex ;; All rights reserved. ; ; Redistribution and use in source and binary forms, with or without @@ -340,9 +340,8 @@ (open-input-file* in))) (define (run/file* thunk) - (let* ((temp-file (create-temporary-file))) - (wait ; This is peculiar - (fork/pipe (lambda () + (let ((temp-file (create-temporary-file))) + (wait (fork (lambda () (let ((fd (file-open temp-file open/wronly))) (duplicate-fileno fd 1) (with-output-to-port (open-output-file* 1) thunk))))) |