diff options
Diffstat (limited to 'source4/auth/credentials/credentials.i')
-rw-r--r-- | source4/auth/credentials/credentials.i | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/source4/auth/credentials/credentials.i b/source4/auth/credentials/credentials.i index 456ea75519..78660bc46c 100644 --- a/source4/auth/credentials/credentials.i +++ b/source4/auth/credentials/credentials.i @@ -26,11 +26,13 @@ #include "includes.h" #include "auth/credentials/credentials.h" +#include "param/param.h" typedef struct cli_credentials cli_credentials; %} -%include "carrays.i" -%include "typemaps.i" +%import "carrays.i" +%import "typemaps.i" +%import "param/param.i" %typemap(default) struct cli_credentials * { $1 = NULL; @@ -44,13 +46,13 @@ typedef struct cli_credentials cli_credentials; $result = PyString_FromStringAndSize($1->hash, 16); } +%talloctype(cli_credentials); %rename(Credentials) cli_credentials; typedef struct cli_credentials { %extend { cli_credentials() { return cli_credentials_init(NULL); } - ~cli_credentials() { talloc_free($self); } /* username */ const char *get_username(void); bool set_username(const char *value, @@ -83,7 +85,7 @@ typedef struct cli_credentials { bool set_workstation(const char *workstation, enum credentials_obtained obtained=CRED_SPECIFIED); - void guess(struct loadparm_context *lp_ctx = NULL); + void guess(struct loadparm_context *lp_ctx); bool is_anonymous(void); const struct samr_Password *get_nt_hash(TALLOC_CTX *mem_ctx); |