Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 2ab685b9 authored by David Duarte's avatar David Duarte
Browse files

PandoraServer: Avoid completing grpcUnary responseObserver twice

Due to a suspension point at the end of the withTimeout block,
a cancelation could happen after calling onCompleted
on the grpc responseObserver.
This cancelation would throw an exception ending in the catch block
with an already completed responseObserver.
Calling onError on an already completed responseObserver ends in
an unhandled IllegalStateException ending the MonitoringInstrumentation.

To solve that we move the suspension point before calling onCompleted.

Bug: 244615429
Test: atest pts-bot
Change-Id: Ia38a3f0a1baf88df081b49622809cca6f61e1e12
parent cd744dfb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment