2 Sep 2011 21:19
Issues with script.test.sh
Faré <fahree <at> gmail.com>
2011-09-02 19:19:54 GMT
2011-09-02 19:19:54 GMT
I tried to run script.test.sh (that tests the --script functionality)
on Linux to a pipe (to tee). It failed miserably at the "--script exit
status from QUIT when stdout closed" test, because closing the stdout
fd causes the pipe to close which causes the process to abort. Ouch. I
tried to redirect to a file instead; this works on Linux. Now it fails
on MacOS X because the unix realpath function (from Apple's libc?)
loses as it returns /dev/fd/$(basename file) instead of the full path
to the file:
CL-USER> (sb-posix:open "/tmp/foo" #o10660)
6
CL-USER> (truename "/dev/fd/6")
#P"/dev/fd/foo"
CL-USER> (sb-posix:readlink "/dev/fd/6")
; Evaluation aborted on #<SB-POSIX:SYSCALL-ERROR {1004B507B1}>.
CL-USER> (describe (sb-posix:lstat "/dev/fd/6"))
#<SB-POSIX:STAT {1004CBC571}>
[standard-object]
Slots with :INSTANCE allocation:
MODE = 33188
INO = 11613310
DEV = 120128676
NLINK = 1
UID = 132098
GID = 0
SIZE = 0
RDEV = 0
ATIME = 1314985242
MTIME = 1314985242
(Continue reading)
RSS Feed