[SCM] Samba Shared Repository - branch v3-2-test updated - initial-v3-2-unstable-1305-g8809eae

Jeremy Allison jra at samba.org
Sat Jan 12 08:28:15 GMT 2008


The branch, v3-2-test has been updated
       via  8809eaeb154ea12543455f589e31172dc905d83a (commit)
      from  c79e9414c4baed6e61fc6a3f766395b873bcc4ea (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test


- Log -----------------------------------------------------------------
commit 8809eaeb154ea12543455f589e31172dc905d83a
Author: Jeremy Allison <jra at samba.org>
Date:   Sat Jan 12 00:15:46 2008 -0800

    CID 458. Don't leak dlopen handles on failing to load
    module.
    Jeremy.

-----------------------------------------------------------------------

Summary of changes:
 source/lib/module.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/lib/module.c b/source/lib/module.c
index fa06d14..285bd9c 100644
--- a/source/lib/module.c
+++ b/source/lib/module.c
@@ -57,6 +57,7 @@ static NTSTATUS do_smb_load_module(const char *module_name, bool is_probe)
 	if (error) {
 		DEBUG(0, ("Error trying to resolve symbol 'init_module' in %s: %s\n", 
 			  module_name, error));
+		sys_dlclose(handle);
 		return NT_STATUS_UNSUCCESSFUL;
 	}
 
@@ -66,6 +67,7 @@ static NTSTATUS do_smb_load_module(const char *module_name, bool is_probe)
 	if (!NT_STATUS_IS_OK(status)) {
 		DEBUG(0, ("Module '%s' initialization failed: %s\n",
 			    module_name, get_friendly_nt_error_msg(status)));
+		sys_dlclose(handle);
 	}
 
 	return status;


-- 
Samba Shared Repository


More information about the samba-cvs mailing list