ndrdump: Don't leak plugin handle on error.
authorAndreas Schneider <asn@samba.org>
Wed, 20 Feb 2013 09:36:52 +0000 (10:36 +0100)
committerAlexander Bokovoy <ab@samba.org>
Fri, 22 Feb 2013 15:36:14 +0000 (16:36 +0100)
Reviewed-by: Alexander Bokovoy <ab@samba.org>
librpc/tools/ndrdump.c

index 7247d8030091ec41295ce966eff6126d61c5a3b2..692e6559480cafecaf1ba3105e71725c641394a8 100644 (file)
@@ -117,6 +117,7 @@ static const struct ndr_interface_table *load_iface_from_plugin(const char *plug
        if (!p) {
                printf("%s: Unable to find DCE/RPC interface table for '%s': %s\n", plugin, pipe_name, dlerror());
                talloc_free(symbol);
+               dlclose(handle);
                return NULL;
        }