全面支持ipv6

This commit is contained in:
ziyue
2022-05-08 16:33:33 +08:00
parent a95bf960e0
commit a44334acaf
11 changed files with 125 additions and 114 deletions

View File

@@ -66,8 +66,10 @@ void RtspPlayer::teardown(){
void RtspPlayer::play(const string &strUrl){
RtspUrl url;
if(!url.parse(strUrl)){
onPlayResult_l(SockException(Err_other,StrPrinter << "illegal rtsp url:" << strUrl),false);
try {
url.parse(strUrl);
} catch (std::exception &ex) {
onPlayResult_l(SockException(Err_other, StrPrinter << "illegal rtsp url:" << ex.what()), false);
return;
}