Fix a memory leak
authorVolker Lendecke <vl@samba.org>
Thu, 27 Mar 2008 21:54:10 +0000 (22:54 +0100)
committerVolker Lendecke <vl@samba.org>
Fri, 28 Mar 2008 12:44:30 +0000 (13:44 +0100)
source/lib/sharesec.c

index 5a8984f4f0389ea904d426dde86095405ad28d7d..2338cca591bc72afea56cd0ce9f67c005725e2a2 100644 (file)
@@ -137,6 +137,8 @@ SEC_DESC *get_share_security( TALLOC_CTX *ctx, const char *servicename,
 
        status = unmarshall_sec_desc(ctx, data.dptr, data.dsize, &psd);
 
+       SAFE_FREE(data.dptr);
+
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(0, ("unmarshall_sec_desc failed: %s\n",
                          nt_errstr(status)));