r7633: this patch started as an attempt to make the dcerpc code use a given
[kamenim/samba.git] / source4 / utils / net / net_password.c
index 68fe9223a121424c0b3cdf27e79655f0d5a83a5c..1912beeb41b3b03479a13fc3bf0b532961e464fb 100644 (file)
@@ -53,7 +53,7 @@ static int net_password_change(struct net_context *ctx, int argc, const char **a
                new_password = getpass(password_prompt);
        }
 
-       libnetctx = libnet_context_init();
+       libnetctx = libnet_context_init(NULL);
        if (!libnetctx) {
                return -1;      
        }
@@ -73,7 +73,7 @@ static int net_password_change(struct net_context *ctx, int argc, const char **a
                return -1;
        }
 
-       libnet_context_destroy(&libnetctx);
+       talloc_free(libnetctx);
 
        return 0;
 }
@@ -128,7 +128,7 @@ static int net_password_set(struct net_context *ctx, int argc, const char **argv
                new_password = getpass(password_prompt);
        }
 
-       libnetctx = libnet_context_init();
+       libnetctx = libnet_context_init(NULL);
        if (!libnetctx) {
                return -1;      
        }
@@ -147,7 +147,7 @@ static int net_password_set(struct net_context *ctx, int argc, const char **argv
                return -1;
        }
 
-       libnet_context_destroy(&libnetctx);
+       talloc_free(libnetctx);
 
        return 0;
 }