summaryrefslogtreecommitdiff
path: root/lib/telnet.c
diff options
context:
space:
mode:
authorSylvestre Ledru <sylvestre@debian.org>2017-03-10 14:28:37 +0100
committerDaniel Stenberg <daniel@haxx.se>2017-03-13 23:11:45 +0100
commit66de563482c0fd4324e1eae19809d2499e3c4fa8 (patch)
treebf3178878ebe2461388e8fec01e321173ffe30f8 /lib/telnet.c
parentdb87bcfcf21f8c3b8188d0c5ab82faf804ffd5ea (diff)
downloadcurl-66de563482c0fd4324e1eae19809d2499e3c4fa8.tar.gz
Improve code readbility
... by removing the else branch after a return, break or continue. Closes #1310
Diffstat (limited to 'lib/telnet.c')
-rw-r--r--lib/telnet.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/telnet.c b/lib/telnet.c
index 162cab757..a7c483dfe 100644
--- a/lib/telnet.c
+++ b/lib/telnet.c
@@ -899,11 +899,9 @@ static CURLcode check_telnet_options(struct connectdata *conn)
result = CURLE_UNKNOWN_TELNET_OPTION;
break;
}
- else {
- failf(data, "Syntax error in telnet option: %s", head->data);
- result = CURLE_TELNET_OPTION_SYNTAX;
- break;
- }
+ failf(data, "Syntax error in telnet option: %s", head->data);
+ result = CURLE_TELNET_OPTION_SYNTAX;
+ break;
}
if(result) {
@@ -1594,7 +1592,7 @@ static CURLcode telnet_do(struct connectdata *conn, bool *done)
if(result == CURLE_AGAIN)
break;
/* returned not-zero, this an error */
- else if(result) {
+ if(result) {
keepon = FALSE;
break;
}