mirror of
https://github.com/hermitcore/libhermit.git
synced 2025-03-09 00:00:03 +01:00
add additional error check
This commit is contained in:
parent
b366f95c36
commit
28ccfdc1ee
1 changed files with 6 additions and 1 deletions
|
@ -663,7 +663,12 @@ int main(int argc, char **argv)
|
|||
int32_t magic = HERMIT_MAGIC;
|
||||
struct sockaddr_in serv_name;
|
||||
|
||||
init_env(argv[1]);
|
||||
ret = init_env(argv[1]);
|
||||
if (ret) {
|
||||
perror("init_env failed");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
atexit(fini_env);
|
||||
|
||||
/* create a socket */
|
||||
|
|
Loading…
Add table
Reference in a new issue