From 91b1815fa9fcc11437b74c4d5e8a0e4e97b40906 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Thu, 9 Mar 2006 00:59:54 +0000 Subject: r14058: Try to make the continuation on the list of password set mechs clearer. Andrew Bartlett (This used to be commit 0aa7160a66ee6951311fd7076faa2d27e25d620d) --- source4/libnet/libnet_passwd.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'source4/libnet/libnet_passwd.c') diff --git a/source4/libnet/libnet_passwd.c b/source4/libnet/libnet_passwd.c index 3ccba754ea..e7a474811f 100644 --- a/source4/libnet/libnet_passwd.c +++ b/source4/libnet/libnet_passwd.c @@ -480,9 +480,12 @@ static NTSTATUS libnet_SetPassword_samr_handle(struct libnet_context *ctx, TALLO for (i=0; i < ARRAY_SIZE(levels); i++) { r->generic.level = levels[i]; status = libnet_SetPassword(ctx, mem_ctx, r); - if (!NT_STATUS_EQUAL(status, NT_STATUS_INVALID_INFO_CLASS) && !NT_STATUS_EQUAL(status, NT_STATUS_NET_WRITE_FAULT)) { - break; + if (NT_STATUS_EQUAL(status, NT_STATUS_INVALID_INFO_CLASS) + || NT_STATUS_EQUAL(status, NT_STATUS_NET_WRITE_FAULT)) { + /* Try another password set mechanism */ + continue; } + break; } return status; -- cgit