diff options
-rw-r--r-- | ircobsbridge.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ircobsbridge.rb b/ircobsbridge.rb index ace7de7..aa89577 100644 --- a/ircobsbridge.rb +++ b/ircobsbridge.rb @@ -29,7 +29,7 @@ end def websocketwrite( json ) $tcp_socket.write( WebSocket::Frame::Outgoing::Client.new( data: json, type: :text ).to_s ) -rescue IOError, EOFError +rescue IOError, EOFError, Errno::ECONNRESET $tcp_socket.close websocket_create() retry @@ -192,7 +192,7 @@ obsreader = Thread.new { rescue IO::WaitReadable, IO::EAGAINWaitReadable, JSON::ParserError IO.select([$tcp_socket]) retry - rescue IOError, EOFError + rescue IOError, EOFError, Errno::ECONNRESET $tcp_socket.close websocket_create() retry |