diff options
author | Dan Fandrich <dan@coneharvesters.com> | 2017-04-30 10:54:26 +0200 |
---|---|---|
committer | Dan Fandrich <dan@coneharvesters.com> | 2017-04-30 10:55:20 +0200 |
commit | 8089dcfc5d4b34b15cee1f1cc9b3124c0279d41b (patch) | |
tree | ea2d07b42ff6e3ceb6632de553dd4d36638796c9 /tests/unit/unit1600.c | |
parent | 65c6caacaee87f2b09aa03e5eed1bcbd9e356f68 (diff) |
tests: fixed OOM handling of unit tests to abort test
It's dangerous to continue to run the test when a memory alloc fails.
Diffstat (limited to 'tests/unit/unit1600.c')
-rw-r--r-- | tests/unit/unit1600.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/unit/unit1600.c b/tests/unit/unit1600.c index f0f9cc1f4..af0ad8435 100644 --- a/tests/unit/unit1600.c +++ b/tests/unit/unit1600.c @@ -29,7 +29,7 @@ CURL *easy; static CURLcode unit_setup(void) { easy = curl_easy_init(); - return CURLE_OK; + return easy ? CURLE_OK : CURLE_OUT_OF_MEMORY; } static void unit_stop(void) |