Opened 18 years ago
Closed 18 years ago
#172 closed defect (fixed)
libc: dup2/dup on tcpip socket doesn't clear the no-inhert/close-on-exec flags
| Reported by: | bird | Owned by: | bird |
|---|---|---|---|
| Priority: | normal | Milestone: | libc-0.6.3 |
| Component: | libc-backend | Version: | 0.6.2 |
| Severity: | normal | Keywords: | dup dup2 socket no-inherit close-on-exec |
| Cc: |
Description
When duplicating a tcpip socket (file descriptor if you like) the no-inherit and close-on-exec flags aren't cleared as they should. This results in code doing socketpair(); ... dup2(fds[1], 1/*stdout*/); _spawn(); to fail. (On example of this is the cups code.)
Note:
See TracTickets
for help on using tickets.

(In [3382]) clear the no-inherit and close-on-exec flags when duplicating a tcpip socket. Fixes #172.