projects
/
project
/
procd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
properly handle return codes
[project/procd.git]
/
initd
/
preinit.c
diff --git
a/initd/preinit.c
b/initd/preinit.c
index
fb94527
..
f38d8ef
100644
(file)
--- a/
initd/preinit.c
+++ b/
initd/preinit.c
@@
-38,7
+38,8
@@
check_dbglvl(void)
if (!fp)
return;
- fscanf(fp, "%d", &lvl);
+ if (fscanf(fp, "%d", &lvl) == EOF)
+ ERROR("failed to read debug level\n");
fclose(fp);
unlink("/tmp/debug_level");