Remove signal handler.

@param $signal
8114
public function removeSignal($signal)
    {
        if (isset($this->_signalEvents[$signal])) {
            $this->_signalEvents[$signal]->del();
            unset($this->_signalEvents[$signal]);
        }
    }
1106210
public function broadcast($signal) {
        if ($signal == SIGINT || $signal == SIGKILL) {
            $this->isStopped = true;
        }
        foreach ($this->handlers as $handler) {
            posix_kill($handler, $signal);
        }
    }
1054736
public function removerHandler(callable $handler) {
        foreach ($this->handlers as $i => $oldHandler) {
            if ($handler == $oldHandler['handler']) {
                unset($this->handlers[$i]);
            }
        }
    }
1020897
public function receive(Signal $signal)
    {
        if (!$signal instanceof Signal\ContentService\DeleteVersionSignal) {
            return;
        }

        $this->runLegacyKernelCallback(
            static function () use ($signal) {
                eZContentCacheManager::clearContentCacheIfNeeded($signal->contentId);
                eZSearch::removeObjectById($signal->contentId, null);
                eZContentOperationCollection::registerSearchObject($signal->contentId);
                eZContentObject::clearCache(); // Clear all object memory cache to free memory
            }
        );
    }
787779
public function signalHandler($signal)
    {
        $this->emit('signal', $signal);
        $this->emit($signal);

        // Default signal process
        if ($this->options['catch_signal']) {
            $this->signalHandlerDefault($signal);
        }
    }
994587
protected function signalHandlerDefault($signal)
    {
        switch ($signal) {
            case SIGTERM:
            case SIGINT:
                // Check children
                while ($this->children) {
                    foreach ($this->children as $child) {
                        $ok = $child->kill(SIGINT);
                        /* EPERM */
                        if (posix_get_last_error() == 1) $ok = false;

                        if ($ok) {
                            // Emit exit
                            $child->emit('abort', $signal);
                            $child->shutdown($signal);
                            $this->clear($child);
                        }
                    }
                }
                $this->emit('abort', $signal);
                $this->shutdown($signal);
                exit;
                break;
        }
    }
796150
public function receive(Signal $signal)
    {
        if (!$signal instanceof Signal\ContentService\DeleteContentSignal) {
            return;
        }

        $this->runLegacyKernelCallback(
            static function () use ($signal) {
                eZContentCacheManager::clearContentCacheIfNeeded($signal->contentId);
                eZSearch::removeObjectById($signal->contentId, null);
                eZContentObject::clearCache(); // Clear all object memory cache to free memory
            }
        );
    }
306470
protected function handleSignal( $signalNumber )
	{
		switch( $signalNumber )
		{
			case SIGTERM:
				$this->signalTerm = TRUE;
				@unlink( $this->filePid );
				break;
			case SIGHUP:
				$this->signalHangup = TRUE;
				break;
			default:
				$this->report( 'Funny signal: ' . $signalNumber );
		}
	}
571180
public function handleSignal($signal)
    {
        if (in_array($signal, $this->stopSignals)) {
            $this->logger->info(sprintf('Handle stop signal (%s)', $signal));
            $this->stop = true;
        } elseif (in_array($signal, $this->pauseSignals)) {
            $this->logger->info(sprintf('Handle pause signal (%s)', $signal));
            $this->pause = true;
        } elseif (in_array($signal, $this->resumeSignals)) {
            $this->logger->info(sprintf('Handle resume signal (%s)', $signal));
            $this->pause = false;
        }
    }
1310439
public function killAll($signal = SIGINT)
    {
        foreach ($this->forks as $fork) {
            $fork->kill($signal);
        }
    }
1059733
def unregister_signal_handlers():
    
    signal.signal(SIGNAL_STACKTRACE, signal.SIG_IGN)
    signal.signal(SIGNAL_PDB, signal.SIG_IGN)
152729
public function receive(Signal $signal)
    {
        if (!$signal instanceof Signal\ContentTypeService\PublishContentTypeDraftSignal) {
            return;
        }

        $this->runLegacyKernelCallback(
            static function () use ($signal) {
                eZExpiryHandler::registerShutdownFunction();
                $handler = eZExpiryHandler::instance();
                $time = time();
                $handler->setTimestamp('user-class-cache', $time);
                $handler->setTimestamp('class-identifier-cache', $time);
                $handler->setTimestamp('sort-key-cache', $time);
                $handler->store();
            }
        );
    }
260700
public static function off($event)
    {
        if (static::bound($event)) {
            unset(
                static::$events[$event],
                static::$events['__bow.transmission.event'][$event],
                static::$events['__bow.once.event'][$event]
            );
        }
    }
394624
def unregister_signals(self):
        """"""
        # Unregister Record signals
        if hasattr(self, 'update_function'):
            records_signals.before_record_insert.disconnect(
                self.update_function)
            records_signals.before_record_update.disconnect(
                self.update_function)
        self.unregister_signals_oaiset()
147430
public function kill($signal = SIGTERM)
    {
        if (!$this->isAlive()) {
            return false;
        }

        if (!proc_terminate($this->resource, $signal)) {
            return false;
        }

        $this->setStreamBlocking();

        while ($this->isAlive()) {
            usleep(50000);
        }

        $this->cleanup();
        return true;
    }
797678
public function kill(string $name, int $signal = SIGTERM): bool
    {
        if ($this->exists($name)) {
            $process = $this->processes->get($name);
            if (Process::kill($process['pid'], $signal)) {
                $this->processes->forget($name);
                $this->processStoreToFile();

                return true;
            }

            return false;
        }

        return false;
    }
1069362
public function signal($signal)
    {
        // Log all signals sent to the daemon.
        $this->getLogger()->debug('Received signal: ' . $signal);

        // Let's make sure we have an application instance.
        if (!is_subclass_of($this, __CLASS__)) {
            $this->getLogger()->emergency('Cannot find the application instance.');

            throw new \RuntimeException('Cannot find the application instance.');
        }

        // @event onReceiveSignal

        switch ($signal) {
            case SIGINT:
            case SIGTERM:
                // Handle shutdown tasks
                if ($this->running && $this->isActive()) {
                    $this->shutdown();
                } else {
                    $this->close();
                }

                break;

            case SIGHUP:
                // Handle restart tasks
                if ($this->running && $this->isActive()) {
                    $this->shutdown(true);
                } else {
                    $this->close();
                }

                break;

            case SIGCHLD:
                // A child process has died
                while ($this->pcntlWait($signal, WNOHANG || WUNTRACED) > 0) {
                    usleep(1000);
                }

                break;

            case SIGCLD:
                while ($this->pcntlWait($signal, WNOHANG) > 0) {
                    $signal = $this->pcntlChildExitStatus($signal);
                }

                break;

            default:
                break;
        }
    }