diff options
author | Karolin Seeger <kseeger@samba.org> | 2014-07-28 09:13:45 +0200 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2014-07-28 09:18:00 +0200 |
commit | fcc634b483255bedf53f3aea40334c018e13dcce (patch) | |
tree | 7d59833bd515e295e70ec188e1aa2b1436b3355c /source3/libsmb/libsmb_setget.c | |
parent | 97d7291d12e803076022d71556c792b0cd4e60e8 (diff) | |
parent | 80a1dfddf9086700a8de5fd6005a9179b0bb3d9e (diff) | |
download | samba-fcc634b483255bedf53f3aea40334c018e13dcce.tar.gz |
Merge commit 'origin/v4-1-test^' into v4-1-stablesamba-4.1.10
This was needed because of a changed commit message (fixed version number)
in v4-1-stable after generating the 'samba-4.1.9' tag.
Karolin
Signed-off-by: Karolin Seeger <kseeger@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source3/libsmb/libsmb_setget.c')
-rw-r--r-- | source3/libsmb/libsmb_setget.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/source3/libsmb/libsmb_setget.c b/source3/libsmb/libsmb_setget.c index b8adcca18b9..3255b522bb0 100644 --- a/source3/libsmb/libsmb_setget.c +++ b/source3/libsmb/libsmb_setget.c @@ -91,9 +91,11 @@ void smbc_setDebug(SMBCCTX *c, int debug) { char buf[32]; + TALLOC_CTX *frame = talloc_stackframe(); snprintf(buf, sizeof(buf), "%d", debug); c->debug = debug; lp_set_cmdline("log level", buf); + TALLOC_FREE(frame); } /** @@ -139,10 +141,15 @@ smbc_setPort(SMBCCTX *c, uint16_t port) smbc_bool smbc_getOptionDebugToStderr(SMBCCTX *c) { + smbc_bool ret; + TALLOC_CTX *frame = talloc_stackframe(); + /* Because this is a global concept, it is better to check * what is really set, rather than what we wanted set * (particularly as you cannot go back to stdout). */ - return debug_get_output_is_stderr(); + ret = debug_get_output_is_stderr(); + TALLOC_FREE(frame); + return ret; } /** Set whether to log to standard error instead of standard output. @@ -154,6 +161,7 @@ smbc_getOptionDebugToStderr(SMBCCTX *c) void smbc_setOptionDebugToStderr(SMBCCTX *c, smbc_bool b) { + TALLOC_CTX *frame = talloc_stackframe(); if (b) { /* * We do not have a unique per-thread debug state? For @@ -164,6 +172,7 @@ smbc_setOptionDebugToStderr(SMBCCTX *c, smbc_bool b) */ setup_logging("libsmbclient", DEBUG_STDERR); } + TALLOC_FREE(frame); } /** @@ -498,7 +507,11 @@ smbc_setOptionUseNTHash(SMBCCTX *c, smbc_bool b) smbc_get_auth_data_fn smbc_getFunctionAuthData(SMBCCTX *c) { - return c->callbacks.auth_fn; + smbc_get_auth_data_fn ret; + TALLOC_CTX *frame = talloc_stackframe(); + ret = c->callbacks.auth_fn; + TALLOC_FREE(frame); + return ret; } /** Set the function for obtaining authentication data */ |