From f4b5f8cdf0cd68be427c7093fde72f07012c36ca Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Wed, 10 Dec 2014 22:43:44 +0100 Subject: ntlm_wb_response: fix "statement not reached" ... and I could use a break instead of a goto to end the loop. Bug: http://curl.haxx.se/mail/lib-2014-12/0089.html Reported-by: Tor Arntsen --- lib/curl_ntlm_wb.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/curl_ntlm_wb.c b/lib/curl_ntlm_wb.c index b83326a9d..5e2d79cb4 100644 --- a/lib/curl_ntlm_wb.c +++ b/lib/curl_ntlm_wb.c @@ -294,7 +294,7 @@ static CURLcode ntlm_wb_response(struct connectdata *conn, len_out += size; if(buf[len_out - 1] == '\n') { buf[len_out - 1] = '\0'; - goto wrfinish; + break; } newbuf = realloc(buf, len_out + NTLM_BUFSIZE); if(!newbuf) { @@ -303,8 +303,7 @@ static CURLcode ntlm_wb_response(struct connectdata *conn, } buf = newbuf; } - goto done; -wrfinish: + /* Samba/winbind installed but not configured */ if(state == NTLMSTATE_TYPE1 && len_out == 3 && -- cgit v1.2.3