Skip to content

Commit

Permalink
plugin_proxy: destroy input context data after exiting the input thread.
Browse files Browse the repository at this point in the history
Signed-off-by: Hiroshi Hatake <[email protected]>
  • Loading branch information
pwhelan authored and cosmo0920 committed Apr 22, 2022
1 parent a7afa3e commit 63e4679
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/flb_plugin_proxy.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,12 @@ static int flb_proxy_input_cb_exit(void *in_context, struct flb_config *config)
it = in_context;
ctx = container_of(it, struct flb_plugin_input_proxy_thread_config, it);

flb_input_thread_destroy(it, ctx->ins);

if (ctx->proxy->def->proxy == FLB_PROXY_GOLANG) {
proxy_go_input_destroy(ctx->proxy->data);
}

flb_input_thread_destroy(it, ctx->ins);

flb_plugin_proxy_destroy(ctx->proxy);

flb_free(ctx);
Expand Down

0 comments on commit 63e4679

Please sign in to comment.