we close stdin as well 727449d1
Anselm R.Garbe · 2006-08-16 09:31 1 file(s) · +4 −3
main.c +4 −3
18 18
/* static */
19 19
20 20
static int (*xerrorxlib)(Display *, XErrorEvent *);
21 -
static Bool otherwm;
21 +
static Bool otherwm, readin;
22 22
23 23
static void
24 24
cleanup()
25 25
{
26 +
	close(STDIN_FILENO);
26 27
	while(sel) {
27 28
		resize(sel, True, TopLeft);
28 29
		unmanage(sel);
146 147
void
147 148
quit(Arg *arg)
148 149
{
149 -
	running = False;
150 +
	readin = running = False;
150 151
}
151 152
152 153
/*
176 177
	int i, j, xfd;
177 178
	unsigned int mask;
178 179
	fd_set rd;
179 -
	Bool readin = True;
180 180
	Window w;
181 181
	XModifierKeymap *modmap;
182 182
	XSetWindowAttributes wa;
279 279
	/* main event loop, also reads status text from stdin */
280 280
	XSync(dpy, False);
281 281
	procevent();
282 +
	readin = True;
282 283
	while(running) {
283 284
		FD_ZERO(&rd);
284 285
		if(readin)