summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/module.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/source3/lib/module.c b/source3/lib/module.c
index 38fcf0f329..2abe918ef4 100644
--- a/source3/lib/module.c
+++ b/source3/lib/module.c
@@ -42,9 +42,8 @@ static NTSTATUS do_smb_load_module(const char *module_name, BOOL is_probe)
if(!handle) {
int level = is_probe ? 3 : 0;
- DEBUG(level, ("Error loading module '%s': %s\n", module_name,
- sys_dlerror()));
-
+ error = sys_dlerror();
+ DEBUG(level, ("Error loading module '%s': %s\n", module_name, error ? error : ""));
return NT_STATUS_UNSUCCESSFUL;
}