Skip to content

Commit

Permalink
http: avoid uninitialized resend_connection_limit condition
Browse files Browse the repository at this point in the history
  • Loading branch information
furmur committed Oct 10, 2024
1 parent c9132bd commit 057dfd6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions apps/http/HttpDestination.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -575,6 +575,9 @@ void HttpDestination::auth_on_timer_event(HttpClient* client, const std::string
void HttpDestination::send_failed_events(HttpClient* client)
{
HttpEvent* event;

if(events.empty()) return;

unsigned int count_will_send = (resend_count_connection.get() < resend_connection_limit) ?
resend_connection_limit - resend_count_connection.get() : 0;
while(!events.empty() &&
Expand Down

0 comments on commit 057dfd6

Please sign in to comment.