summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharles Hardin <charles.hardin@chargepoint.com>2020-08-11 13:18:45 -0700
committerCharles Hardin <charles.hardin@chargepoint.com>2020-08-11 13:20:16 -0700
commit8dd858e5f893558ccfca09410402e3b7b5897e20 (patch)
tree44d3b35d128b5602019ec6ad89c7a35d036940f1
parenta80cecd0d73c86c7f7bc8f2b6a0987fae5136465 (diff)
downloadbluez-tools-8dd858e5f893558ccfca09410402e3b7b5897e20.tar.gz
Correct the signal handler registration bt-agent
Integration with systemd showed that the bt-agent was not terminating on a SIGTERM being sent seems evident from the typo on the handler registration for the TERM being assign to the usr1_handler. Signed-off-by: Charles Hardin <charles.hardin@chargepoint.com>
-rw-r--r--src/bt-agent.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bt-agent.c b/src/bt-agent.c
index 95c069c..9e4d0c2 100644
--- a/src/bt-agent.c
+++ b/src/bt-agent.c
@@ -274,9 +274,9 @@ int main(int argc, char *argv[])
}
/* Add SIGTERM/SIGINT/SIGUSR1 handlers */
- g_unix_signal_add (SIGTERM, usr1_signal_handler, NULL);
+ g_unix_signal_add (SIGTERM, term_signal_handler, NULL);
g_unix_signal_add (SIGINT, term_signal_handler, NULL);
- g_unix_signal_add (SIGUSR1, term_signal_handler, NULL);
+ g_unix_signal_add (SIGUSR1, usr1_signal_handler, NULL);
g_main_loop_run(mainloop);