rest: do not exit() if execlp() fails

execlp() should not ever fail, but if it ever happens, return -1 instead of
exitting this daemon.
master v1.2.5-6
OpenGnSys Support Team 2023-12-15 11:11:45 +01:00
parent 5e8e1c6467
commit b100c570a0
1 changed files with 1 additions and 1 deletions

View File

@ -1247,7 +1247,7 @@ static int og_set_client_mode(struct og_dbi *dbi, const char *mac,
"/opt/opengnsys/bin/setclientmode", filename, NULL);
syslog(LOG_ERR, "failed script execution (%s:%d)\n",
__func__, __LINE__);
exit(EXIT_FAILURE);
return -1;
} else {
wait(&status);
}