mirror of
https://github.com/troglobit/finit.git
synced 2026-10-02 14:02:52 +07:00
conf_reload(): Exit properly, even if no /etc/finit.d/*.conf exitsts
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
+2
-1
@@ -516,7 +516,7 @@ int conf_reload(void)
|
||||
num = scandir(rcsd, &e, NULL, alphasort);
|
||||
if (num < 0) {
|
||||
_d("Skipping %s, no files found ...", rcsd);
|
||||
return 0;
|
||||
goto done;
|
||||
}
|
||||
|
||||
for (i = 0; i < num; i++) {
|
||||
@@ -566,6 +566,7 @@ int conf_reload(void)
|
||||
free(e[num]);
|
||||
free(e);
|
||||
|
||||
done:
|
||||
/* Drop record of all .conf changes */
|
||||
drop_changes();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user