Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
51a03f63
Commit
51a03f63
authored
Feb 22, 2017
by
charsyam
Committed by
charsyam
Mar 01, 2018
Browse files
fix dlopen leak
parent
83b5b5a4
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/module.c
View file @
51a03f63
...
@@ -3939,6 +3939,7 @@ int moduleLoad(const char *path, void **module_argv, int module_argc) {
...
@@ -3939,6 +3939,7 @@ int moduleLoad(const char *path, void **module_argv, int module_argc) {
}
}
onload
=
(
int
(
*
)(
void
*
,
void
**
,
int
))(
unsigned
long
)
dlsym
(
handle
,
"RedisModule_OnLoad"
);
onload
=
(
int
(
*
)(
void
*
,
void
**
,
int
))(
unsigned
long
)
dlsym
(
handle
,
"RedisModule_OnLoad"
);
if
(
onload
==
NULL
)
{
if
(
onload
==
NULL
)
{
dlclose
(
handle
);
serverLog
(
LL_WARNING
,
serverLog
(
LL_WARNING
,
"Module %s does not export RedisModule_OnLoad() "
"Module %s does not export RedisModule_OnLoad() "
"symbol. Module not loaded."
,
path
);
"symbol. Module not loaded."
,
path
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment