Skip to content

Commit

Permalink
Also rethrow when upgrading websocket
Browse files Browse the repository at this point in the history
  • Loading branch information
Zentrik committed Aug 29, 2023
1 parent 767cde7 commit dc84d3d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/WebSockets.jl
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,9 @@ function upgrade(f::Function, http::Streams.Stream; suppress_close_error::Bool=f
close(ws, CloseFrameBody(1011, "Unexpected server websocket error"))
end
end
if !isok(e)
rethrow()
end
finally
if !isclosed(ws)
close(ws, CloseFrameBody(1000, ""))
Expand Down

0 comments on commit dc84d3d

Please sign in to comment.