1
0
mirror of https://github.com/samba-team/samba.git synced 2025-11-05 04:23:51 +03:00

r26320: Clean up properly after error.

This commit is contained in:
Jelmer Vernooij
2007-12-06 21:39:56 +01:00
committed by Stefan Metzmacher
parent 95a6ef7fc8
commit 9fdfe1ad8c
2 changed files with 2 additions and 3 deletions

View File

@@ -50,9 +50,7 @@ typedef struct cli_credentials {
cli_credentials() {
return cli_credentials_init(NULL);
}
~cli_credentials() {
talloc_free($self);
}
~cli_credentials() { talloc_free($self); }
/* username */
const char *get_username(void);
bool set_username(const char *value,

View File

@@ -41,6 +41,7 @@ int cli_credentials_get_krb5_context(struct cli_credentials *cred,
ret = smb_krb5_init_context(cred, cli_credentials_get_event_context(cred),
lp_ctx, &cred->smb_krb5_context);
if (ret) {
cred->smb_krb5_context = NULL;
return ret;
}
*smb_krb5_context = cred->smb_krb5_context;