Details
-
Type:
Bug
-
Status: Closed
-
Priority:
P2: Important
-
Resolution: Done
-
Affects Version/s: 6.2.3
-
Fix Version/s: 6.2.5, 6.3.1, 6.4.0 Beta1
-
Component/s: Core: Threads
-
Labels:None
-
Story Points:5
-
Commits:76a1c060ac (qt/qtbase/dev) 76a1c060ac (qt/tqtc-qtbase/dev) ae162d444f (qt/qtbase/6.3) a4acc78216 (qt/qtbase/6.3) a4acc78216 (qt/tqtc-qtbase/6.3) ae162d444f (qt/tqtc-qtbase/6.3) c9a7bedfc3 (qt/tqtc-qtbase/6.2)
-
Sprint:Team A Foundation Sprint 53, Team A Foundation Sprint 54
Description
The docs for QPromise::~QPromise() state that the promise transitions to a canceled state on destruction, unless finish() is called.
However, if the promise is never start()-ed but it gets deleted, then the associated future never gets canceled, and as a result QFuture::waitForFinished() will never return, ever.
Is this intended behavior? I believe that if a QPromise is never started but deleted, it should still somehow signal to associated futures which call waitForFinished() to return.