From: Jeremy Allison Date: Tue, 21 Jul 2020 00:01:04 +0000 (-0700) Subject: s3: libsmb: Cleanup - change to early continue in internal_resolve_name() for name_re... X-Git-Tag: talloc-2.3.2~966 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=75469fcfbffdcf2bef83f5814f562de1fed86a48;p=thirdparty%2Fsamba.git s3: libsmb: Cleanup - change to early continue in internal_resolve_name() for name_resolve_bcast(). No logic change. Signed-off-by: Jeremy Allison Reviewed-by: Isaac Boukris --- diff --git a/source3/libsmb/namequery.c b/source3/libsmb/namequery.c index e72504cfcaf..5d4b1ee545f 100644 --- a/source3/libsmb/namequery.c +++ b/source3/libsmb/namequery.c @@ -2748,15 +2748,16 @@ NTSTATUS internal_resolve_name(const char *name, status = name_resolve_bcast( name, name_type, talloc_tos(), &ss_list, return_count); - if (NT_STATUS_IS_OK(status)) { - if (!convert_ss2service(return_iplist, - ss_list, - return_count)) { - status = NT_STATUS_NO_MEMORY; - goto fail; - } - goto done; + if (!NT_STATUS_IS_OK(status)) { + continue; } + if (!convert_ss2service(return_iplist, + ss_list, + return_count)) { + status = NT_STATUS_NO_MEMORY; + goto fail; + } + goto done; } else { DEBUG(0,("resolve_name: unknown name switch type %s\n", tok));