core: Add error reporting for corrupted symbols (#4458)

This commit is contained in:
Adrian Cojocaru
2026-08-11 19:20:59 +03:00
committed by GitHub
parent 7f430aa624
commit d9664ee187
39 changed files with 331 additions and 29 deletions

View File

@@ -1737,5 +1737,17 @@ void NativeMapView::onRenderError(std::exception_ptr) {
}
}
void NativeMapView::onSymbolError(const std::string& message) {
assert(vm != nullptr);
android::UniqueEnv _env = android::AttachEnv();
static auto& javaClass = jni::Class<NativeMapView>::Singleton(*_env);
static auto onSymbolError = javaClass.GetMethod<void(jni::String)>(*_env, "onSymbolError");
auto weakReference = javaPeer.get(*_env);
if (weakReference) {
weakReference.Call(*_env, onSymbolError, jni::Make<jni::String>(*_env, message));
}
}
} // namespace android
} // namespace mbgl