mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-11 17:59:03 +00:00
Added: ignore sigpipe signal generated by libwww
This commit is contained in:
parent
6166dde8ee
commit
5976ece759
1 changed files with 16 additions and 0 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
|
||||||
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
||||||
// Copyright (C) 2010 Winch Gate Property Limited
|
// Copyright (C) 2010 Winch Gate Property Limited
|
||||||
//
|
//
|
||||||
|
@ -28,6 +29,8 @@
|
||||||
#ifdef NL_OS_WINDOWS
|
#ifdef NL_OS_WINDOWS
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#include <shellapi.h>
|
#include <shellapi.h>
|
||||||
|
#else
|
||||||
|
#include <csignal>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef NL_OS_MAC
|
#ifdef NL_OS_MAC
|
||||||
|
@ -108,6 +111,15 @@ void quitCrashReport ()
|
||||||
contReset(CrashCounterSock);
|
contReset(CrashCounterSock);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef NL_OS_WINDOWS
|
||||||
|
static void sigHandler(int Sig)
|
||||||
|
{
|
||||||
|
// redirect the signal for the next time
|
||||||
|
signal(Sig, sigHandler);
|
||||||
|
nlwarning("Ignoring signal SIGPIPE");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//---------------------------------------------------
|
//---------------------------------------------------
|
||||||
// MAIN :
|
// MAIN :
|
||||||
// Entry for the Application.
|
// Entry for the Application.
|
||||||
|
@ -527,6 +539,10 @@ int main(int argc, char **argv)
|
||||||
|
|
||||||
strcpy(filename, argv[0]);
|
strcpy(filename, argv[0]);
|
||||||
|
|
||||||
|
|
||||||
|
// ignore signal SIGPIPE generated by libwww
|
||||||
|
signal(SIGPIPE, sigHandler);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// initialize patch manager and set the ryzom full path, before it's used
|
// initialize patch manager and set the ryzom full path, before it's used
|
||||||
|
|
Loading…
Reference in a new issue