mirror of
https://github.com/openharmony/developtools_syscap_codec.git
synced 2026-08-27 02:11:19 -04:00
+1
-1
@@ -448,7 +448,7 @@ static int32_t FreeAfterDecodePCID(struct FreeDecodePcidJsonInfo freePcidJsonInf
|
||||
{
|
||||
switch (type) {
|
||||
case FREE_DECODE_PCID_CONVERT_OUT:
|
||||
free(freePcidJsonInfo.strJson);
|
||||
cJSON_free(freePcidJsonInfo.strJson);
|
||||
cJSON_Delete(freePcidJsonInfo.jsonRootObj);
|
||||
FreeContextBuffer(freePcidJsonInfo.contextBuffer);
|
||||
break;
|
||||
|
||||
+2
-1
@@ -285,9 +285,10 @@ int32_t RPCIDDecode(char *inputFile, char *outputPath)
|
||||
ret = ConvertedContextSaveAsFile(outputPath, "rpcid.json", convertedBuffer, strlen(convertedBuffer));
|
||||
if (ret != 0) {
|
||||
PRINT_ERR("ConvertedContextSaveAsFile failed, outputPath:%s, filename:rpcid.json\n", outputPath);
|
||||
cJSON_free(convertedBuffer);
|
||||
goto FREE_RPCID_ROOT;
|
||||
}
|
||||
|
||||
cJSON_free(convertedBuffer);
|
||||
FREE_RPCID_ROOT:
|
||||
cJSON_Delete(rpcidRoot);
|
||||
FREE_CONTEXT_OUT:
|
||||
|
||||
Reference in New Issue
Block a user