Skip to content
Snippets Groups Projects
Commit 726a0852 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Fix new small memory leak (no need to use strdup here)

Fix CID 497098
parent e7642321
Branches
Tags
1 merge request!455Update branch with changes from master
Pipeline #6480 passed
...@@ -322,7 +322,7 @@ parse_file_name(JSContext *cx, JSObject* obj) ...@@ -322,7 +322,7 @@ parse_file_name(JSContext *cx, JSObject* obj)
JS_ReportError(cx, "Invalid '%s' string in file object", prop_name); JS_ReportError(cx, "Invalid '%s' string in file object", prop_name);
return NULL; return NULL;
} }
return strdup(cp); return cp;
} }
JS_ReportError(cx, "Missing '%s' string in file object", prop_name); JS_ReportError(cx, "Missing '%s' string in file object", prop_name);
return NULL; return NULL;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment