]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4-libnet Always return after composite_error()
authorAndrew Bartlett <abartlet@samba.org>
Mon, 23 Apr 2012 07:28:39 +0000 (17:28 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 23 Apr 2012 12:29:44 +0000 (14:29 +0200)
These instances should not cause a problem, but make it easier to audit for
this kind of problem in the future with grep.

Andrew Bartlett

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Mon Apr 23 14:29:45 CEST 2012 on sn-devel-104

source4/libnet/libnet_group.c
source4/libnet/libnet_user.c
source4/winbind/wb_sid2gid.c
source4/winbind/wb_sid2uid.c

index b12037e1f388c3d2aa1465b8fdda659485977c5f..928ce69225285c4a64f8f11986c4cd7161d39f67 100644 (file)
@@ -680,10 +680,11 @@ static void continue_groups_enumerated(struct tevent_req *subreq)
 
                /* that's it */
                composite_done(c);
-
+               return;
        } else {
                /* something went wrong */
                composite_error(c, c->status);
+               return;
        }
 }
 
index e56ed498c2a0511f50c4ac47f1ef912f8f95be50..dc0691ac22951b81f8ea033e153e169fecd6e9f3 100644 (file)
@@ -1146,10 +1146,12 @@ static void continue_users_enumerated(struct tevent_req *subreq)
                
                /* that's it */
                composite_done(c);
+               return;
 
        } else {
                /* something went wrong */
                composite_error(c, c->status);
+               return;
        }
 }
 
index 0b3589561fcda1c85e05649e1d5aaccba931df26..e1061544d24ca29154e1edb0a0f5a0a70c9b52cf 100644 (file)
@@ -84,8 +84,10 @@ static void sid2gid_recv_gid(struct composite_context *ctx)
            ids->xid.type == ID_TYPE_GID) {
                state->gid = ids->xid.id;
                composite_done(state->ctx);
+               return;
        } else {
                composite_error(state->ctx, NT_STATUS_INVALID_SID);
+               return;
        }
 }
 
index f1d9bdd6779a89aa0dfd1cf66a472e46675d8ecb..2b5fec538100e4e1f1064962b7f5438aee8666f0 100644 (file)
@@ -84,8 +84,10 @@ static void sid2uid_recv_uid(struct composite_context *ctx)
            ids->xid.type == ID_TYPE_UID) {
                state->uid = ids->xid.id;
                composite_done(state->ctx);
+               return;
        } else {
                composite_error(state->ctx, NT_STATUS_INVALID_SID);
+               return;
        }
 }