Ignore:
Timestamp:
May 24, 2009, 7:55:48 AM (16 years ago)
Author:
Herwig Bauernfeind
Message:

Update Samba 3.3 branch to 3.3.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/samba-3.3.x/source/utils/net_rpc.c

    r221 r224  
    121121        DOM_SID *domain_sid;
    122122        const char *domain_name;
     123        int ret = -1;
    123124
    124125        /* make use of cli_state handed over as an argument, if possible */
     
    142143        if (!(mem_ctx = talloc_init("run_rpc_command"))) {
    143144                DEBUG(0, ("talloc_init() failed\n"));
    144                 cli_shutdown(cli);
    145                 return -1;
     145                goto fail;
    146146        }
    147147
     
    149149                                              &domain_name);
    150150        if (!NT_STATUS_IS_OK(nt_status)) {
    151                 cli_shutdown(cli);
    152                 return -1;
     151                goto fail;
    153152        }
    154153
     
    165164                                DEBUG(0, ("Could not initialise schannel netlogon pipe. Error was %s\n",
    166165                                        nt_errstr(nt_status) ));
    167                                 cli_shutdown(cli);
    168                                 return -1;
     166                                goto fail;
    169167                        }
    170168                } else {
     
    185183                                                debug_ctx(), cli, interface),
    186184                                        nt_errstr(nt_status) ));
    187                                 cli_shutdown(cli);
    188                                 return -1;
     185                                goto fail;
    189186                        }
    190187                }
     
    196193                DEBUG(1, ("rpc command function failed! (%s)\n", nt_errstr(nt_status)));
    197194        } else {
     195                ret = 0;
    198196                DEBUG(5, ("rpc command function succedded\n"));
    199197        }
     
    205203        }
    206204
     205fail:
    207206        /* close the connection only if it was opened here */
    208207        if (!cli_arg) {
     
    211210
    212211        talloc_destroy(mem_ctx);
    213         return (!NT_STATUS_IS_OK(nt_status));
     212        return ret;
    214213}
    215214
     
    61286127        nt_status = rpccli_samr_Connect2(pipe_hnd, mem_ctx,
    61296128                                         pipe_hnd->desthost,
    6130                                          SAMR_ACCESS_OPEN_DOMAIN,
     6129                                         SAMR_ACCESS_LOOKUP_DOMAIN,
    61316130                                         &connect_hnd);
    61326131        if (!NT_STATUS_IS_OK(nt_status)) {
Note: See TracChangeset for help on using the changeset viewer.