Skip to content

Commit

Permalink
upstream: always remove keepalive close event on shutdown if registered
Browse files Browse the repository at this point in the history
Resolves this issue: fluent#6821

Signed-off-by: Wesley Pettit <[email protected]>
  • Loading branch information
PettitWesley authored and Swapneil Singh committed Oct 22, 2024
1 parent eba89f4 commit 6b3b67f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/flb_upstream.c
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ static int prepare_destroy_conn(struct flb_upstream_conn *u_conn)
flb_trace("[upstream] destroy connection #%i to %s:%i",
u_conn->fd, u->tcp_host, u->tcp_port);

if (u->flags & FLB_IO_ASYNC || u_conn->ka_dropped_event_added == FLB_TRUE) {
if (MK_EVENT_IS_REGISTERED((&u_conn->event))) {
mk_event_del(u_conn->evl, &u_conn->event);
}

Expand Down

0 comments on commit 6b3b67f

Please sign in to comment.