X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Utils%2FDaemon%2FDaemon.cc;h=d6b8d917dbb5b410c578072317f029912077a4a2;hb=9348e1098d66ac2684c8e280abf8d7143c887982;hp=2b09cc03bb6c6194419b7c836f30a39e73c893fa;hpb=23ef68f7c443f0993b2b46cd912666c040fdccba;p=senf.git diff --git a/Utils/Daemon/Daemon.cc b/Utils/Daemon/Daemon.cc index 2b09cc0..d6b8d91 100644 --- a/Utils/Daemon/Daemon.cc +++ b/Utils/Daemon/Daemon.cc @@ -363,6 +363,15 @@ prefix_ void senf::Daemon::fork() ::sigemptyset(&cldsig); LIBC_CALL( ::sigaddset, (&cldsig, SIGCHLD) ); LIBC_CALL( ::sigprocmask, (SIG_BLOCK, &cldsig, &oldsig) ); + + if (! senf::scheduler::empty() ) + std::cerr << + "\n" + "*** WARNING ***\n" + "Scheduler not empty before fork(). THIS MUST NOT HAPPEN.\n" + "The scheduler will be reinitialized by the fork() and lose all registrations.\n" + "*** WARNING ***\n" + "\n"; LIBC_CALL_RV( pid, ::fork, () );