summaryrefslogtreecommitdiffstats
path: root/src/gui/platform/android/qandroidnativeinterface.cpp
diff options
context:
space:
mode:
authorPiotr Wiercinski <piotr.wiercinski@qt.io>2023-12-27 12:34:00 +0100
committerPiotr WierciƄski <piotr.wiercinski@qt.io>2023-12-28 11:57:08 +0000
commit1e6841245dca3bda5dee050fc841c7129142dd9f (patch)
treea6468150c2b23bee72f49d6cca05fde0971a2d6c /src/gui/platform/android/qandroidnativeinterface.cpp
parentddad911f9be71d3a1396e28261ffe386e880aa69 (diff)
wasm: Fix handling of promise pool in WebPromiseManager
Promises are registered upon entry to the pool and unregistered upon exit. If all promises are in a 'pending' state, new promises can't be processed. Upon completion of a registered promise, it is unregistered, allowing space for a new promise. The code path responsible for unregistering promises when they resolve runs each time a promise's callback is called. Unfortunately, there's no guarantee that the callback will be invoked upon the promise's resolution. For instance, promises registered with only a 'catch' callback may never be triggered when the promise resolves correctly. This commit ensures that a final callback is always registered, even if the user did not provide one. This guarantees that promises are always unregistered upon resolution Fixes: QTBUG-118161 Pick-to: 6.5 6.6 6.7 Change-Id: Ifea93d692464a6ef40c4bcad60f840ca0cb650c9 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
Diffstat (limited to 'src/gui/platform/android/qandroidnativeinterface.cpp')
0 files changed, 0 insertions, 0 deletions