diff options
author | Daniel Stenberg <daniel@haxx.se> | 2016-04-03 16:21:10 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2016-04-03 22:38:36 +0200 |
commit | a981141b199702ffd780a4390e601db565102c65 (patch) | |
tree | c92b2a21887fb1f9683372c2564584d1ee79fea7 /tests/unit/unit1305.c | |
parent | d3252e000c96f31456667c3033c13d83e2628d29 (diff) | |
download | curl-a981141b199702ffd780a4390e601db565102c65.tar.gz |
unit: make unit test source code checksrc compliant
Diffstat (limited to 'tests/unit/unit1305.c')
-rw-r--r-- | tests/unit/unit1305.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/unit/unit1305.c b/tests/unit/unit1305.c index c99435d68..093333a79 100644 --- a/tests/unit/unit1305.c +++ b/tests/unit/unit1305.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -48,7 +48,7 @@ static CURLcode unit_setup( void ) { int rc; data = curl_easy_init(); - if (!data) + if(!data) return CURLE_OUT_OF_MEMORY; rc = Curl_mk_dnscache(&hp); @@ -62,7 +62,7 @@ static CURLcode unit_setup( void ) static void unit_stop( void ) { - if (data_node) { + if(data_node) { Curl_freeaddrinfo(data_node->addr); free(data_node); } @@ -103,15 +103,15 @@ static Curl_addrinfo *fake_ai(void) static CURLcode create_node(void) { data_key = aprintf("%s:%d", "dummy", 0); - if (!data_key) + if(!data_key) return CURLE_OUT_OF_MEMORY; data_node = calloc(1, sizeof(struct Curl_dns_entry)); - if (!data_node) + if(!data_node) return CURLE_OUT_OF_MEMORY; data_node->addr = fake_ai(); - if (!data_node->addr) + if(!data_node->addr) return CURLE_OUT_OF_MEMORY; return CURLE_OK; @@ -124,7 +124,7 @@ UNITTEST_START size_t key_len; /* Test 1305 exits without adding anything to the hash */ - if (strcmp(arg, "1305") != 0) { + if(strcmp(arg, "1305") != 0) { CURLcode rc = create_node(); abort_unless(rc == CURLE_OK, "data node creation failed"); key_len = strlen(data_key); |