Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
make not closing fds?
While building a release I saw in fstat that commands started from make
had many (pipe) file descriptors allocated. Is make missing
setting FD_CLOEXEC/closing before fork on these ? While this is not
really critical it opens up possibilities to clobber at least the output
and gobble up
input data with misbehaved programs.
Frank
Example:
USER CMD PID FD MOUNT INUM MODE SZ|DV R/W
root rm 4126 wd /fs/raid1a 2666534 drwxr-xr-x 512 r
root rm 4126 0 /tmp 85401585450532163 -rw-------
1053 rw
root rm 4126 1 / 11534468 crw-rw-rw- null w
root rm 4126 2* pipe 0xfffffe8680442708 ->
0xfffffe87ded81040 w
root rm 4126 3* pipe 0xfffffe8681282468 ->
0xfffffe87acd3f2f8 w
root rm 4126 4* pipe 0xfffffe874dfe4590 ->
0xfffffe8749cb25b0 w
root rm 4126 5 /fs/raid1a 2666537 -rw-r--r-- 25192 w
root rm 4126 6* pipe 0xfffffe8680442708 ->
0xfffffe87ded81040 w
root rm 4126 7* pipe 0xfffffe818d2b9290 ->
0xfffffe8781eb1598 w
...more up to fs 40
root cat 25766 wd /fs/raid1a 1985407 drwxr-xr-x 512 r
root cat 25766 0 /tmp 85401585450180222 -rw-------
750 rw
root cat 25766 1* pipe 0xfffffe867fee2460 ->
0xfffffe87e59a0538 w
root cat 25766 2* pipe 0xfffffe867fee2460 ->
0xfffffe87e59a0538 w
root cat 25766 3* pipe 0xfffffe8681282468 ->
0xfffffe87acd3f2f8 w
root cat 25766 4* pipe 0xfffffe874dfe4590 ->
0xfffffe8749cb25b0 w
root cat 25766 5* pipe 0xfffffe87acd3f2f8 <-
0xfffffe8681282468 rn
root cat 25766 6* pipe 0xfffffe86cdd9c840 ->
0xfffffe879aeed430 w
...more up to fd 30
Home |
Main Index |
Thread Index |
Old Index