Check hangup error in voip (#146423)

Check hangup error

Prevent an error where the call end future may have already been set
when a hangup is detected.
This commit is contained in:
Jamin 2025-06-10 09:22:53 -05:00 committed by Franck Nijhof
parent 97d91ddddb
commit 2b08c4c344
No known key found for this signature in database
GPG Key ID: AB33ADACE7101952

View File

@ -336,7 +336,8 @@ class VoipAssistSatellite(VoIPEntity, AssistSatelliteEntity, RtpDatagramProtocol
if self._run_pipeline_task is not None:
_LOGGER.debug("Cancelling running pipeline")
self._run_pipeline_task.cancel()
self._call_end_future.set_result(None)
if not self._call_end_future.done():
self._call_end_future.set_result(None)
self.disconnect()
break