forked from RepentantGopher/tnt-kafka
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
patch: fix use after free in rdhttp.c
- Loading branch information
1 parent
b892514
commit 7b20672
Showing
2 changed files
with
13 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
diff --git a/src/rdhttp.c b/src/rdhttp.c | ||
index dca6c6f8..5a290c5b 100644 | ||
--- a/src/rdhttp.c | ||
+++ b/src/rdhttp.c | ||
@@ -345,6 +345,7 @@ rd_http_error_t *rd_http_post_expect_json(rd_kafka_t *rk, | ||
|
||
/* Retry */ | ||
rd_http_error_destroy(herr); | ||
+ herr = 0; | ||
rd_usleep(retry_ms * 1000 * (i + 1), &rk->rk_terminate); | ||
} | ||
|