Skip to content

Commit

Permalink
Fix while condition
Browse files Browse the repository at this point in the history
  • Loading branch information
maxsharabayko committed Jul 3, 2024
1 parent f6ff1ea commit 3ffc91e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions xtransmit/misc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ void common_run(const vector<string>& urls, const stats_config& cfg_stats, const
// make_unique is not supported by GCC 4.8, only starting from GCC 4.9 :(
try {
stats = unique_ptr<socket::stats_writer>(
new socket::stats_writer(cfg_stats.stats_file, milliseconds(cfg_stats.stats_freq_ms)));
new socket::stats_writer(cfg_stats.stats_file, cfg_stats.stats_format, milliseconds(cfg_stats.stats_freq_ms)));
}
catch (const socket::exception& e)
{
Expand Down Expand Up @@ -145,7 +145,7 @@ void common_run(const vector<string>& urls, const stats_config& cfg_stats, const
}

// Closing a listener socket (if any) will not allow further connections.
if (close_listener)
if (cfg_conn.close_listener)
listening_sock.reset();

if (stats)
Expand All @@ -163,7 +163,7 @@ void common_run(const vector<string>& urls, const stats_config& cfg_stats, const
}
} while ((cfg_conn.reconnect || processing_pipes.size() < cfg_conn.client_conns) && !force_break);

while (processing_pipes.empty())
while (!processing_pipes.empty())
{
try
{
Expand Down

0 comments on commit 3ffc91e

Please sign in to comment.