• Philip Chimento's avatar
    js: Use correct autoptr in gjs_string_to_filename() · 9ddca8b4
    Philip Chimento authored
    The return value of g_filename_from_utf8() (must be freed with g_free())
    was getting assigned to a GjsAutoJSChar (which would be freed with
    JS_free()). Instead gjs_string_to_filename() must have a GjsAutoChar
    output parameter.
    This requires changing gjs_parse_call_args() as well. We improve it by
    allowing to pass in autoptrs for 's' or 'F' args instead of char**.
    Fixes a few minor memory leaks, mostly in error paths in Cairo functions.
cairo-svg-surface.cpp 3.79 KB