Change-Id: I62bc3ea48938a4f54e9f47218d4025e954a6d566
pJitProfTable = (unsigned char *)malloc(JIT_PROF_SIZE);
if (!pJitProfTable) {
ALOGE("jit prof table allocation failed");
- free(pJitProfTable);
+ free(pJitTable);
dvmUnlockMutex(&gDvmJit.tableLock);
goto fail;
}
calloc(1, sizeof(*pJitTraceProfCounters));
if (!pJitTraceProfCounters) {
ALOGE("jit trace prof counters allocation failed");
+ free(pJitTable);
+ free(pJitProfTable);
dvmUnlockMutex(&gDvmJit.tableLock);
goto fail;
}