Skip to content

Commit

Permalink
when one side of the relay dies, kill the other (#179)
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Mar 27, 2024
1 parent 36a2216 commit df22be2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/udx.c
Original file line number Diff line number Diff line change
Expand Up @@ -855,7 +855,10 @@ close_maybe (udx_stream_t *stream, int err) {
for (uint32_t i = 0; i < relaying.size; i++) {
udx_stream_t *stream = (udx_stream_t *) relaying.values[i];

if (stream) stream->relay_to = NULL;
if (stream) {
stream->relay_to = NULL;
udx_stream_destroy(stream);
}
}

udx__cirbuf_destroy(&stream->relaying_streams);
Expand Down

0 comments on commit df22be2

Please sign in to comment.