more libstrongswan-like error handling in optionsfrom

This commit is contained in:
Martin Willi
2007-10-03 15:02:29 +00:00
parent 8bcdf1562c
commit 6a8e7381d0
3 changed files with 36 additions and 53 deletions
+4 -2
View File
@@ -291,8 +291,10 @@ int main(int argc, char **argv)
{
snprintf(path, BUF_LEN, "%s/%s", OPENAC_PATH, optarg);
}
optionsfrom(path, &argc, &argv, optind, stderr);
/* does not return on error */
if (!optionsfrom(path, &argc, &argv, optind))
{
exit(1);
}
}
continue;