1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

net/libnetapi: Include netapi headers early and free on exit.

Guenther
(This used to be commit 020b1e6431)
This commit is contained in:
Günther Deschner 2008-04-16 02:16:08 +02:00
parent 46e6bc1153
commit 0a362a94c8
3 changed files with 9 additions and 3 deletions

View File

@ -1169,6 +1169,13 @@ static struct functable net_func[] = {
rc = net_run_function(argc_new-1, argv_new+1, net_func, net_help);
DEBUG(2,("return code = %d\n", rc));
{
struct libnetapi_ctx *ctx = NULL;
libnetapi_getctx(&ctx);
libnetapi_free(ctx);
}
TALLOC_FREE(frame);
return rc;
}

View File

@ -22,6 +22,8 @@
* include
*/
#include "lib/netapi/netapi.h"
typedef NTSTATUS (*rpc_command_fn)(const DOM_SID *,
const char *,
struct cli_state *cli,

View File

@ -19,7 +19,6 @@
#include "includes.h"
#include "utils/net.h"
#include "lib/netapi/netapi.h"
static int net_dom_usage(int argc, const char **argv)
{
@ -130,7 +129,6 @@ static int net_dom_unjoin(int argc, const char **argv)
cli_shutdown(cli);
}
/* libnetapi_free(ctx); */
return ret;
}
@ -244,7 +242,6 @@ static int net_dom_join(int argc, const char **argv)
cli_shutdown(cli);
}
/* libnetapi_free(ctx); */
return ret;
}