---
surf.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/surf.c b/surf.c
index 70cd2c7..a672d2d 100644
--- a/surf.c
+++ b/surf.c
_AT_@ -197,6 +197,7 @@ static void scroll(GtkAdjustment *a, const Arg *arg);
static void setatom(Client *c, int a, const char *v);
static void setup(void);
static void sigchld(int unused);
+static void sighup(int unused);
static void source(Client *c, const Arg *arg);
static void spawn(Client *c, const Arg *arg);
static void stop(Client *c, const Arg *arg);
_AT_@ -1300,6 +1301,8 @@ setup(void)
/* clean up any zombies immediately */
sigchld(0);
+ if (signal(SIGHUP, sighup) == SIG_ERR)
+ die("Can't install SIGHUP handler");
gtk_init(NULL, NULL);
dpy = GDK_DISPLAY();
_AT_@ -1395,6 +1398,16 @@ sigchld(int unused)
}
void
+sighup(int unused)
+{
+ Arg a = { .b = FALSE };
+ Client *c;
+
+ for (c = clients; c; c = c->next)
+ reload(c, &a);
+}
+
+void
source(Client *c, const Arg *arg)
{
Arg a = { .b = FALSE };
--
2.6.4
Received on Sat Jan 09 2016 - 20:18:53 CET
This archive was generated by hypermail 2.3.0 : Sat Jan 09 2016 - 20:24:16 CET