From ba0bf87d967a9544b9c97525994a43ad5b6f1f60 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Mon, 21 Apr 2008 20:14:32 +0200 Subject: net: Add libnetapi context to net's impressive list of globals. Guenther (This used to be commit 8a5fadf6a183e4e4ccc77283b3ddba0748c6abfb) --- source3/utils/net.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'source3/utils/net.c') diff --git a/source3/utils/net.c b/source3/utils/net.c index f6851f69da6..c4b31d46b07 100644 --- a/source3/utils/net.c +++ b/source3/utils/net.c @@ -89,6 +89,7 @@ int opt_testmode = False; int opt_have_ip = False; struct sockaddr_storage opt_dest_ip; bool smb_encrypt; +struct libnetapi_ctx *netapi_ctx = NULL; extern bool AllowDebugChange; @@ -1170,11 +1171,7 @@ static struct functable net_func[] = { DEBUG(2,("return code = %d\n", rc)); - { - struct libnetapi_ctx *ctx = NULL; - libnetapi_getctx(&ctx); - libnetapi_free(ctx); - } + libnetapi_free(netapi_ctx); TALLOC_FREE(frame); return rc; -- cgit