From: RĂ©mi Denis-Courmont Date: Sun, 11 Apr 2010 09:07:46 +0000 (+0300) Subject: Always use the SIGPIPE hack even if not needed, it cannot hurt X-Git-Tag: 1.1.0-pre1~44 X-Git-Url: https://git.sesse.net/?p=vlc;a=commitdiff_plain;h=61053dc0050ca2eacc979b1c2468de80157db0e2 Always use the SIGPIPE hack even if not needed, it cannot hurt --- diff --git a/bin/vlc.c b/bin/vlc.c index 9ccbdd8940..5d6fec3502 100644 --- a/bin/vlc.c +++ b/bin/vlc.c @@ -54,11 +54,12 @@ extern char *FromLocale (const char *); *****************************************************************************/ int main( int i_argc, const char *ppsz_argv[] ) { -#ifdef __APPLE__ - /* The so-called POSIX-compliant MacOS X is not. - * SIGPIPE fires even when it is blocked in all threads! */ + /* The so-called POSIX-compliant MacOS X reportedly processes SIGPIPE even + * if it is blocked in all thread. Also some libraries want SIGPIPE blocked + * as they have no clue about signal masks. + * Note: this is NOT an excuse for not protecting against SIGPIPE. If + * LibVLC runs outside of VLC, we cannot rely on this code snippet. */ signal (SIGPIPE, SIG_IGN); -#endif #ifndef ALLOW_RUN_AS_ROOT if (geteuid () == 0)