Skip to content

Commit

Permalink
Exporter: Filter normal read and write errors.(ossrs#3364)
Browse files Browse the repository at this point in the history
  • Loading branch information
chundonglinlin committed Jan 6, 2023
1 parent 3c6ade8 commit 23dd860
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion trunk/src/app/srs_app_statistic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,11 @@ void SrsStatistic::on_disconnect(std::string id, srs_error_t err)
stream->nb_clients--;
vhost->nb_clients--;

if (srs_error_code(err) != ERROR_SUCCESS) {
// TODO: FIXME: Should filter the err.
int err_code = srs_error_code(err);
if (err_code != ERROR_SUCCESS && err_code != ERROR_SOCKET_READ && err_code != ERROR_SOCKET_WRITE
&& err_code != ERROR_SRT_IO)
{
nb_errs_++;
}

Expand Down

0 comments on commit 23dd860

Please sign in to comment.