mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 04:09:49 +00:00
Reconnect within MessageReceiver
This commit is contained in:
@@ -59,6 +59,7 @@ import {
|
||||
} from '../textsecure.d';
|
||||
import { SignalService as Proto } from '../protobuf';
|
||||
|
||||
import { ConnectTimeoutError } from './Errors';
|
||||
import MessageSender from './SendMessage';
|
||||
|
||||
// TODO: remove once we move away from ArrayBuffers
|
||||
@@ -305,15 +306,7 @@ async function _connectSocket(
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
const timer = setTimeout(() => {
|
||||
reject(
|
||||
makeHTTPError(
|
||||
'_connectSocket: Connection timed out',
|
||||
-1,
|
||||
{},
|
||||
'Connection timed out',
|
||||
stack
|
||||
)
|
||||
);
|
||||
reject(new ConnectTimeoutError('Connection timed out'));
|
||||
|
||||
client.abort();
|
||||
}, timeout);
|
||||
|
||||
Reference in New Issue
Block a user