diff --git a/plugins/out_s3/s3_multipart.c b/plugins/out_s3/s3_multipart.c index f8cc4d13b47..967a27420f2 100644 --- a/plugins/out_s3/s3_multipart.c +++ b/plugins/out_s3/s3_multipart.c @@ -192,6 +192,7 @@ static struct multipart_upload *upload_from_file(struct flb_s3 *ctx, if (ret == -1) { flb_plg_error(ctx->ins, "Could not read file metadata: %s", fsf->name); + flb_free(buffered_data); return NULL; }