[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug in close_stdout_status on Solaris 2.7 and 2.8?
From: |
Shei, Shing-Shong |
Subject: |
Re: Bug in close_stdout_status on Solaris 2.7 and 2.8? |
Date: |
Mon, 26 Aug 2002 09:07:55 -0500 |
Jim,
Could it be due to the fact that textutils-2.1's cat doesn't `close'
> the descriptor for standard output?
Yes, this is the case. See the attached trace outputs.
> Would you please send me the two trace-* files produced by running
> these commands?
> truss -o trace-gnu cat /usr/demo/SOUND/sounds/ring.au > /dev/audio
> truss -o trace-sun /usr/bin/cat /usr/demo/SOUND/sounds/ring.au >
/dev/audio
Attached.
> Here's a patch that might solve the problem.
Yes, it does. Thank you very much for the quick response. Have a nice day.
Bruce
execve("/nfs/grumpy/home/user3/shei/cat", 0xFFBEF94C, 0xFFBEF958) argc = 2
mmap(0x00000000, 8192, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_ANON,
-1, 0) = 0xFF3A0000
resolvepath("/usr/lib/ld.so.1", "/usr/lib/ld.so.1", 1023) = 16
open("/var/ld/ld.config", O_RDONLY) Err#2 ENOENT
open("/usr/lib/libgen.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF074) = 0
mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF390000
mmap(0x00000000, 98304, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF370000
mmap(0xFF386000, 2335, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED,
3, 24576) = 0xFF386000
munmap(0xFF376000, 65536) = 0
memcntl(0xFF370000, 6932, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
close(3) = 0
open("/usr/lib/libnsl.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF074) = 0
mmap(0xFF390000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) =
0xFF390000
mmap(0x00000000, 704512, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF280000
mmap(0xFF31C000, 32732, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED,
3, 573440) = 0xFF31C000
mmap(0xFF324000, 30920, PROT_READ|PROT_WRITE|PROT_EXEC,
MAP_PRIVATE|MAP_FIXED|MAP_ANON, -1, 0) = 0xFF324000
munmap(0xFF30C000, 65536) = 0
memcntl(0xFF280000, 82236, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
close(3) = 0
open("/usr/lib/libc.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF074) = 0
mmap(0xFF390000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) =
0xFF390000
mmap(0x00000000, 794624, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF180000
mmap(0xFF23A000, 24668, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED,
3, 696320) = 0xFF23A000
munmap(0xFF22A000, 65536) = 0
memcntl(0xFF180000, 113332, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
close(3) = 0
open("/usr/lib/libdl.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF074) = 0
mmap(0xFF390000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) =
0xFF390000
close(3) = 0
open("/usr/lib/libmp.so.2", O_RDONLY) = 3
fstat(3, 0xFFBEF074) = 0
mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF360000
mmap(0x00000000, 90112, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF340000
mmap(0xFF354000, 865, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3,
16384) = 0xFF354000
munmap(0xFF344000, 65536) = 0
memcntl(0xFF340000, 3124, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
close(3) = 0
open("/usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEEF04) = 0
mmap(0xFF360000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) =
0xFF360000
mmap(0x00000000, 16384, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF270000
close(3) = 0
munmap(0xFF360000, 8192) = 0
fstat64(1, 0xFFBEF850) = 0
open64("/usr/demo/SOUND/sounds/ring.au", O_RDONLY) = 3
fstat64(3, 0xFFBEF850) = 0
brk(0x00025470) = 0
brk(0x00029470) = 0
read(3, " . s n d\0\0\0 0\0\098C7".., 8192) = 8192
write(1, " . s n d\0\0\0 0\0\098C7".., 8192) = 8192
read(3, " ; + $ ! ! % - >D6B2A69F".., 8192) = 8192
write(1, " ; + $ ! ! % - >D6B2A69F".., 8192) = 8192
read(3, " }FF7FFFFEFF ~ ~FDFCFEFC".., 8192) = 8192
write(1, " }FF7FFFFEFF ~ ~FDFCFEFC".., 8192) = 8192
read(3, " ~ ~FCFCFAF8F9FDFBFAF9FD".., 8192) = 8192
write(1, " ~ ~FCFCFAF8F9FDFBFAF9FD".., 8192) = 8192
read(3, "FCF8F7F8FAFAFAFAFAFBFBFE".., 8192) = 6391
write(1, "FCF8F7F8FAFAFAFAFAFBFBFE".., 6391) = 6391
read(3, 0x00025478, 8192) = 0
close(3) = 0
llseek(0, 0, SEEK_CUR) = 1076
_exit(0)
execve("/usr/bin/cat", 0xFFBEF964, 0xFFBEF970) argc = 2
mmap(0x00000000, 8192, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_ANON,
-1, 0) = 0xFF3A0000
resolvepath("/usr/lib/ld.so.1", "/usr/lib/ld.so.1", 1023) = 16
open("/var/ld/ld.config", O_RDONLY) Err#2 ENOENT
open("/usr/lib/libc.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF08C) = 0
mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF390000
mmap(0x00000000, 794624, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF280000
mmap(0xFF33A000, 24668, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED,
3, 696320) = 0xFF33A000
munmap(0xFF32A000, 65536) = 0
memcntl(0xFF280000, 113332, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0
close(3) = 0
open("/usr/lib/libdl.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEF08C) = 0
mmap(0xFF390000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) =
0xFF390000
close(3) = 0
open("/usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1", O_RDONLY) = 3
fstat(3, 0xFFBEEF1C) = 0
mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF380000
mmap(0x00000000, 16384, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF370000
close(3) = 0
munmap(0xFF380000, 8192) = 0
brk(0x00022A18) = 0
brk(0x00024A18) = 0
fstat64(1, 0xFFBEF868) = 0
open64("/usr/demo/SOUND/sounds/ring.au", O_RDONLY) = 3
fstat64(3, 0xFFBEF7D0) = 0
llseek(3, 0, SEEK_CUR) = 0
mmap64(0x00000000, 39159, PROT_READ, MAP_SHARED, 3, 0) = 0xFF360000
read(3, " .", 1) = 1
memcntl(0xFF360000, 39159, MC_ADVISE, MADV_SEQUENTIAL, 0, 0) = 0
write(1, " . s n d\0\0\0 0\0\098C7".., 39159) = 39159
llseek(3, 39159, SEEK_SET) = 39159
munmap(0xFF360000, 39159) = 0
llseek(3, 0, SEEK_CUR) = 39159
close(3) = 0
close(1) (sleeping...)
close(1) = 0
llseek(0, 0, SEEK_CUR) = 14801
_exit(0)