cocos creator 3.0.1
NDK 19.2.5345600
targetSdkVersion 29
ABI armeabi-v7a:arm64-v8a
We found a crash on android device.
Trace the log we found the crash point is free headers of urlConnection.
char *headers = urlConnection.getResponseHeaders();
if (nullptr != headers) {
writeHeaderData(headers, strlen(headers), response);
}
try {
free(headers);
headers = NULL;
} catch (std::exception &e) {
CC_LOG_WARNING("HttpClient exception: %s", e.what());
}
It is not always occur, it seems not have a way to make crash 100%.
I hope there is a guide to help fix this crash.
Thanks.