Skip to content

Commit 19fa31f

Browse files
committed
fix: uncancellable was not forwarding errors to the result promise
1 parent 8c5268f commit 19fa31f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

flow/genericactors.actor.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -239,8 +239,12 @@ Future<Void> triggerOnError( Func what, Future<Void> signal ) {
239239
ACTOR template<class T>
240240
void uncancellable(Future<T> what, Promise<T> result)
241241
{
242-
T val = wait(what);
243-
result.send(val);
242+
try {
243+
T val = wait(what);
244+
result.send(val);
245+
} catch( Error &e ) {
246+
result.sendError(e);
247+
}
244248
}
245249

246250
//Waits for a future to complete and cannot be cancelled

0 commit comments

Comments
 (0)