Skip to content

Commit

Permalink
Report both udp and tcp port for WebRTC.
Browse files Browse the repository at this point in the history
  • Loading branch information
winlinvip committed Sep 5, 2024
1 parent 2e79d00 commit 504e93b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion trunk/src/app/srs_app_heartbeat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,12 @@ srs_error_t SrsHttpHeartbeat::do_heartbeat()
obj->set("rtc", o);

int endpoint = _srs_config->get_rtc_server_listen();
o->append(SrsJsonAny::str(srs_int2str(endpoint).c_str()));
o->append(SrsJsonAny::str(srs_fmt("udp://0.0.0.0:%d", endpoint).c_str()));

if (_srs_config->get_rtc_server_tcp_enabled()) {
endpoint = _srs_config->get_rtc_server_tcp_listen();
o->append(SrsJsonAny::str(srs_fmt("tcp://0.0.0.0:%d", endpoint).c_str()));
}
}
}

Expand Down

0 comments on commit 504e93b

Please sign in to comment.