Resolved some memory leaks in mergJSONDecode