410cf577aee4c7fadede5e032d9de9f523b11fa0
[dotfiles.git] / config.h / slstatus / sigusr.patch
1 ---
2 slstatus.c | 6 +++---
3 1 file changed, 3 insertions(+), 3 deletions(-)
4
5 diff --git a/slstatus.c b/slstatus.c
6 index 96fa5b6..499cd30 100644
7 --- a/slstatus.c
8 +++ b/slstatus.c
9 @@ -26,9 +26,8 @@ static Display *dpy;
10 static void
11 terminate(const int signo)
12 {
13 - (void)signo;
14 -
15 - done = 1;
16 + if (signo != SIGUSR1)
17 + done = 1;
18 }
19
20 static void
21 @@ -72,6 +71,7 @@ main(int argc, char *argv[])
22 act.sa_handler = terminate;
23 sigaction(SIGINT, &act, NULL);
24 sigaction(SIGTERM, &act, NULL);
25 + sigaction(SIGUSR1, &act, NULL);
26
27 if (!sflag && !(dpy = XOpenDisplay(NULL))) {
28 die("XOpenDisplay: Failed to open display");
29 --
30 2.20.1