diff options
author | Volker Lendecke <vl@samba.org> | 2009-05-30 09:54:14 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2009-05-30 09:54:37 +0200 |
commit | e9d1197b4ef79e23067a27ecace5843926b2bf26 (patch) | |
tree | 6d53a1cb08a0180b6c4eaa2e4ad96f4659f86774 /nsswitch/libwbclient | |
parent | 625851a50f74024f5918e0b348147457c2cc42ea (diff) | |
download | samba-e9d1197b4ef79e23067a27ecace5843926b2bf26.tar.gz samba-e9d1197b4ef79e23067a27ecace5843926b2bf26.tar.bz2 samba-e9d1197b4ef79e23067a27ecace5843926b2bf26.zip |
talloc_strdup "dir" in wb_context_init
Diffstat (limited to 'nsswitch/libwbclient')
-rw-r--r-- | nsswitch/libwbclient/wbc_async.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/nsswitch/libwbclient/wbc_async.c b/nsswitch/libwbclient/wbc_async.c index 6a572f4203..5f985f9d5a 100644 --- a/nsswitch/libwbclient/wbc_async.c +++ b/nsswitch/libwbclient/wbc_async.c @@ -200,10 +200,14 @@ struct wb_context *wb_context_init(TALLOC_CTX *mem_ctx, const char* dir) result->is_priv = false; if (dir != NULL) { - result->dir = dir; + result->dir = talloc_strdup(result, dir); } else { result->dir = winbindd_socket_dir(); } + if (result->dir == NULL) { + TALLOC_FREE(result); + return NULL; + } return result; } |