Synchronet now requires the libarchive development package (e.g. libarchive-dev on Debian-based Linux distros, libarchive.org for more info) to build successfully.

Commit ba714636 authored by rswindell's avatar rswindell

Bug-fix: introduced js_sprintf_free() to solve DLL malloc/free issue

(assertion) with jsexec->js_printf(). Sorry Deuce. :-)
parent b318b141
......@@ -65,3 +65,9 @@ js_sprintf(JSContext *cx, uint argn, uintN argc, jsval *argv)
return xp_asprintf_end(p);
}
void DLLCALL
js_sprintf_free(char* p)
{
xp_asprintf_free(p);
}
......@@ -357,7 +357,7 @@ js_printf(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
*rval = STRING_TO_JSVAL(JS_NewStringCopyZ(cx, p));
free(p);
js_sprintf_free(p);
return(JS_TRUE);
}
......
......@@ -1025,6 +1025,7 @@ extern "C" {
/* js_sprintf.c */
DLLEXPORT char* DLLCALL js_sprintf(JSContext* cx, uint argn, uintN argc, jsval *argv);
DLLEXPORT void DLLCALL js_sprintf_free(char *);
/* js_console.cpp */
JSObject* js_CreateConsoleObject(JSContext* cx, JSObject* parent);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment