Skip to content
This repository has been archived by the owner on Sep 9, 2024. It is now read-only.

Commit

Permalink
Android - Move std::rethrow_exception to GameThread
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakub Audykowicz committed Sep 11, 2023
1 parent a5efbcc commit 5e785ac
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions DolbyIO/Source/Private/Utils/DolbyIOErrorHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ namespace DolbyIO

void FErrorHandler::operator()(std::exception_ptr&& ExcPtr) const
{
#if PLATFORM_ANDROID
return AsyncTask(ENamedThreads::GameThread,
[ExcP = MoveTemp(ExcPtr), CopySelf = *this]
{
try
{
std::rethrow_exception(ExcP);
}
catch (...)
{
CopySelf.HandleError();
}
});
#endif
HandleError([ExcP = MoveTemp(ExcPtr)] { std::rethrow_exception(ExcP); });
}

Expand Down

0 comments on commit 5e785ac

Please sign in to comment.