From 495f958b9ac5c45196e743fcba300fcfd25b90a3 Mon Sep 17 00:00:00 2001 From: Sona Kurazyan Date: Thu, 26 Mar 2020 13:22:46 +0100 Subject: Store QFuture exceptions as std::exception_ptr Replaced the internal ExceptionHolder for storing QException* by std::exception_ptr. This will allow to report and store exceptions of types that are not derived from QException. Task-number: QTBUG-81588 Change-Id: I96be919d8289448b3e608310e51a16cebc586301 Reviewed-by: Vitaly Fanaskov Reviewed-by: Qt CI Bot --- src/concurrent/qtconcurrentthreadengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/concurrent/qtconcurrentthreadengine.cpp') diff --git a/src/concurrent/qtconcurrentthreadengine.cpp b/src/concurrent/qtconcurrentthreadengine.cpp index 7f91a2ba68..3293c49507 100644 --- a/src/concurrent/qtconcurrentthreadengine.cpp +++ b/src/concurrent/qtconcurrentthreadengine.cpp @@ -324,7 +324,7 @@ void ThreadEngineBase::handleException(const QException &exception) { if (futureInterface) futureInterface->reportException(exception); - else + else if (!exceptionStore.hasException()) exceptionStore.setException(exception); } #endif -- cgit v1.2.3