History

network: prevent SIGPIPE on OSX

OSX does not know MSG_NOSIGNAL, and provides its own non-standard mechanism instead. I guess Apple hates standards.

wm4 committed 11 years ago

Commit c41e0ae1 parent e9d646f1 file · +4 −0Browse files

Unified · Split

libavformat/network.c+4−0
@@ -180,6 +180,10 @@ int ff_socket(int af, int type, int proto) · 179 unmodified lines
180 }180 }
181#endif181#endif
182 }182 }
183#ifdef SO_NOSIGPIPE
184 if (fd != -1)
185 setsockopt(fd, SOL_SOCKET, SO_NOSIGPIPE, &(int){1}, sizeof(int));
186#endif
183 return fd;187 return fd;
184}188}
185 189

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t