X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Frun-program.lisp;h=aee63b8bb13482512eb2cbd92b97a9e29ed106aa;hb=c716f6ea5255afeb33a1181535b5c067aa9d6aaa;hp=fc02f3ef625dd86af36836b17a57319fa948a3c6;hpb=a0a198faba322eccaf947862b59946aed99b2347;p=sbcl.git diff --git a/src/code/run-program.lisp b/src/code/run-program.lisp index fc02f3e..aee63b8 100644 --- a/src/code/run-program.lisp +++ b/src/code/run-program.lisp @@ -97,25 +97,21 @@ (options sb-alien:int) (rusage sb-alien:int)) -(defconstant wait-wnohang #-svr4 1 #+svr4 #o100) -(defconstant wait-wuntraced #-svr4 2 #+svr4 4) -(defconstant wait-wstopped #-svr4 #o177 #+svr4 wait-wuntraced) - (defun wait3 (&optional do-not-hang check-for-stopped) "Return any available status information on child process. " (multiple-value-bind (pid status) (c-wait3 (logior (if do-not-hang - wait-wnohang + sb-unix:wnohang 0) (if check-for-stopped - wait-wuntraced + sb-unix:wuntraced 0)) 0) (cond ((or (minusp pid) (zerop pid)) nil) ((eql (ldb (byte 8 0) status) - wait-wstopped) + sb-unix:wstopped) (values pid :stopped (ldb (byte 8 8) status))) @@ -429,6 +425,7 @@ (stderr sb-alien:int)) ;;; Is UNIX-FILENAME the name of a file that we can execute? +;;; XXX does this actually work for symlinks? (defun unix-filename-is-executable-p (unix-filename) (declare (type simple-string unix-filename)) (values (and (eq (sb-unix:unix-file-kind unix-filename) :file)