Permalink
Browse files

use a more descriptive error message when execl fails

  • Loading branch information...
1 parent 7cacf6f commit 059157588df410af6676f2cb257156ef5c9ecc60 @falconindy falconindy committed Dec 5, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 wakeup.c
View
@@ -65,7 +65,8 @@ do_suspend(void)
if(pid == 0) {
execlp(SUSPEND_COMMAND, SUSPEND_COMMAND, NULL);
- fprintf(stderr, "error: exec: %s\n", strerror(errno));
+ fprintf(stderr, "error: failed to execute %s: %s\n", SUSPEND_COMMAND,
+ strerror(errno));
_exit(0);
}

0 comments on commit 0591575

Please sign in to comment.