From 56ab5cdbe0bddb3edaf0e7bf82f2c04cea6e64a4 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Thu, 20 Jul 2017 14:44:51 +0200 Subject: [PATCH] s4:lib/http: remove indentation level from http_parse_auth_response() Signed-off-by: Stefan Metzmacher Reviewed-by: Andreas Schneider --- source4/lib/http/http_auth.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/source4/lib/http/http_auth.c b/source4/lib/http/http_auth.c index d134bd65219..701d9b3bae3 100644 --- a/source4/lib/http/http_auth.c +++ b/source4/lib/http/http_auth.c @@ -61,17 +61,19 @@ static NTSTATUS http_parse_auth_response(enum http_auth_method auth, struct http_header *h; for (h = auth_response->headers; h != NULL; h = h->next) { - if (strncasecmp(h->key, "WWW-Authenticate", 16) == 0) { - switch (auth) { - case HTTP_AUTH_NTLM: - if (strncasecmp(h->value, "NTLM ", 5) == 0) { - *in = data_blob_string_const(h->value); - return NT_STATUS_OK; - } - break; - default: - break; + if (strncasecmp(h->key, "WWW-Authenticate", 16) != 0) { + continue; + } + + switch (auth) { + case HTTP_AUTH_NTLM: + if (strncasecmp(h->value, "NTLM ", 5) == 0) { + *in = data_blob_string_const(h->value); + return NT_STATUS_OK; } + break; + default: + break; } } -- 2.11.4.GIT