Skip to content

Commit

Permalink
Include variety of terminate proccess signals handler in discovery se…
Browse files Browse the repository at this point in the history
…rver (#4278)

* Refs #19587: Include SIGHUP handler

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>

* Refs #19587: Handle more signals

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>

* Refs #19587: Move proper signals to 'linux only' case

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>

* Refs #19587: Apply Miguel suggestion

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>

* Refs #19587: Fix Windows build

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>

---------

Signed-off-by: JesusPoderoso <jesuspoderoso@eprosima.com>
(cherry picked from commit 6eb1170)
  • Loading branch information
JesusPoderoso authored and mergify[bot] committed Jan 30, 2024
1 parent 5290e99 commit 401d3ba
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tools/fds/server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,10 @@ int fastdds_discovery_server(
// Handle signal SIGINT for every thread
signal(SIGINT, sigint_handler);
signal(SIGTERM, sigint_handler);
#ifndef _WIN32
signal(SIGQUIT, sigint_handler);
signal(SIGHUP, sigint_handler);
#endif // ifndef _WIN32

bool has_security = false;
if (guid_prefix != pServer->guid().guidPrefix)
Expand Down

0 comments on commit 401d3ba

Please sign in to comment.