X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Finspircd_io.cpp;h=fcbb83aaeb18a57cbc495f68cfda81a436b5f471;hb=d5fed3976bba0f1082522da9b79b6b1cc93d4c56;hp=83c302d90f9c4af5c5795c400699fe7971520892;hpb=e06a27ff0c52acbee3299614c2f60d2cb53a9e60;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/inspircd_io.cpp b/src/inspircd_io.cpp index 83c302d90..fcbb83aae 100644 --- a/src/inspircd_io.cpp +++ b/src/inspircd_io.cpp @@ -26,6 +26,7 @@ #include "inspircd_io.h" #include "inspircd_util.h" #include "inspstring.h" +#include "helperfuncs.h" using namespace std; @@ -87,22 +88,15 @@ void WritePID(std::string filename) } } -void DeadPipe(int status) -{ - signal (SIGPIPE, DeadPipe); -} int DaemonSeed (void) { int childpid; signal (SIGALRM, SIG_IGN); signal (SIGHUP, Rehash); - signal (SIGPIPE, DeadPipe); + signal (SIGPIPE, SIG_IGN); signal (SIGTERM, Exit); - signal (SIGABRT, Exit); signal (SIGSEGV, Error); - signal (SIGURG, Exit); - signal (SIGKILL, Exit); if ((childpid = fork ()) < 0) return (ERROR); else if (childpid > 0) @@ -512,7 +506,7 @@ int ReadConf(std::stringstream *config, const char* tag, const char* var, int in const char* buf = config->str().c_str(); long bptr = 0; - long len = strlen(buf); + long len = config->str().length(); ptr = 0; in_token = 0;