diff options
author | Sylvestre Ledru <sylvestre@debian.org> | 2017-03-10 14:28:37 +0100 |
---|---|---|
committer | ng0 <ng0@infotropique.org> | 2017-08-22 15:23:07 +0000 |
commit | a5d2c8957d189b7334a7d010ebd3ee9bfc69353d (patch) | |
tree | 9b326952663ad3e93b79ee45e970a4033d705daf /lib/hash.c | |
parent | 1a95371f1faba5da824f9248aac607514556bbfc (diff) | |
download | gnurl-a5d2c8957d189b7334a7d010ebd3ee9bfc69353d.tar.gz gnurl-a5d2c8957d189b7334a7d010ebd3ee9bfc69353d.tar.bz2 gnurl-a5d2c8957d189b7334a7d010ebd3ee9bfc69353d.zip |
Improve code readbility
... by removing the else branch after a return, break or continue.
Closes #1310
Diffstat (limited to 'lib/hash.c')
-rw-r--r-- | lib/hash.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/hash.c b/lib/hash.c index 065504235..c26be0118 100644 --- a/lib/hash.c +++ b/lib/hash.c @@ -91,10 +91,8 @@ Curl_hash_init(struct curl_hash *h, } return 0; /* fine */ } - else { - h->slots = 0; - return 1; /* failure */ - } + h->slots = 0; + return 1; /* failure */ } static struct curl_hash_element * @@ -347,10 +345,8 @@ Curl_hash_next_element(struct curl_hash_iterator *iter) struct curl_hash_element *he = iter->current_element->ptr; return he; } - else { - iter->current_element = NULL; - return NULL; - } + iter->current_element = NULL; + return NULL; } #if 0 /* useful function for debugging hashes and their contents */ |