log error if execvp fails in wm_kb_spawn
This commit is contained in:
parent
53a41568b0
commit
a1c5adece5
6
src/wm.c
6
src/wm.c
@ -596,7 +596,11 @@ void wm_kb_spawn(Wm *wm, Arg *args)
|
||||
if (wm->display)
|
||||
close(ConnectionNumber(wm->display));
|
||||
setsid();
|
||||
execvp(args->sl[0], &(args->sl[1]));
|
||||
|
||||
int ret = execvp(args->sl[0], &(args->sl[1]));
|
||||
if (ret == -1) {
|
||||
fprintf(stderr, "wm: could not run %s: %s\n", args->sl[0], strerror(errno));
|
||||
}
|
||||
|
||||
exit(0);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user