mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-28 14:23:30 +01:00
Check return value of crypto_global_init in test.c
This will let the unit tests fail in a less mystifying way if the crypto subsystem is b0rken, and will also make Coverity happier. CID # 429.
This commit is contained in:
parent
eca982d3eb
commit
0317dc2bb2
@ -1318,7 +1318,10 @@ main(int c, const char **v)
|
||||
}
|
||||
|
||||
options->command = CMD_RUN_UNITTESTS;
|
||||
crypto_global_init(0, NULL, NULL);
|
||||
if (crypto_global_init(0, NULL, NULL)) {
|
||||
printf("Can't initialize crypto subsystem; exiting.\n");
|
||||
return 1;
|
||||
}
|
||||
rep_hist_init();
|
||||
network_init();
|
||||
setup_directory();
|
||||
|
Loading…
Reference in New Issue
Block a user