ffmpeg | branch: master | wm4 <nfx...@googlemail.com> | Sat May 30 20:50:43 2015 +0200| [c41e0aedf5fc2a92502bc400010e64b8fea89d4e] | committer: Michael Niedermayer
network: prevent SIGPIPE on OSX OSX does not know MSG_NOSIGNAL, and provides its own non-standard mechanism instead. I guess Apple hates standards. Signed-off-by: Michael Niedermayer <michae...@gmx.at> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c41e0aedf5fc2a92502bc400010e64b8fea89d4e --- libavformat/network.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavformat/network.c b/libavformat/network.c index 8cc5aad..47ade8c 100644 --- a/libavformat/network.c +++ b/libavformat/network.c @@ -180,6 +180,10 @@ int ff_socket(int af, int type, int proto) } #endif } +#ifdef SO_NOSIGPIPE + if (fd != -1) + setsockopt(fd, SOL_SOCKET, SO_NOSIGPIPE, &(int){1}, sizeof(int)); +#endif return fd; } _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog