diff options
author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2018-11-28 16:01:40 +0200 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2018-12-05 08:55:26 -0300 |
commit | b597afa45a40ed2720659649e77dd25b45383fc0 (patch) | |
tree | 583c4a846d826d0e23b866408e512747c7470009 /tools/btinfo.c | |
parent | 5202ea57a8fda7b298bb920a05c349897377abc1 (diff) | |
download | bluez-b597afa45a40ed2720659649e77dd25b45383fc0.tar.gz |
shared/mainloop: Remove mainloop_set_signal
This removes mainloop_set_signal and replaces it usage with
mainloop_run_with_signal.
Diffstat (limited to 'tools/btinfo.c')
-rw-r--r-- | tools/btinfo.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/tools/btinfo.c b/tools/btinfo.c index 8e36577d7..5e609739c 100644 --- a/tools/btinfo.c +++ b/tools/btinfo.c @@ -226,7 +226,6 @@ int main(int argc, char *argv[]) const char *str; bool use_raw = false; bool power_down = false; - sigset_t mask; int fd, i, exit_status; for (;;) { @@ -284,12 +283,6 @@ int main(int argc, char *argv[]) mainloop_init(); - sigemptyset(&mask); - sigaddset(&mask, SIGINT); - sigaddset(&mask, SIGTERM); - - mainloop_set_signal(&mask, signal_callback, NULL, NULL); - printf("Bluetooth information utility ver %s\n", VERSION); fd = socket(AF_BLUETOOTH, SOCK_RAW | SOCK_CLOEXEC, BTPROTO_HCI); @@ -345,7 +338,7 @@ int main(int argc, char *argv[]) return EXIT_FAILURE; } - exit_status = mainloop_run(); + exit_status = mainloop_run_with_signal(signal_callback, NULL); bt_hci_unref(hci_dev); |