Skip to content

Commit

Permalink
in_exec: use flb_calloc to fill NULL (fluent#5715)
Browse files Browse the repository at this point in the history
Signed-off-by: Takahiro Yamashita <[email protected]>
Signed-off-by: Manal Geries <[email protected]>
  • Loading branch information
nokute78 authored and mgeriesa committed Oct 25, 2022
1 parent 838cf39 commit de6d3f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/in_exec/in_exec.c
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ static int in_exec_init(struct flb_input_instance *in,
int ret = -1;

/* Allocate space for the configuration */
ctx = flb_malloc(sizeof(struct flb_exec));
ctx = flb_calloc(1, sizeof(struct flb_exec));
if (!ctx) {
return -1;
}
Expand Down

0 comments on commit de6d3f5

Please sign in to comment.