diff --git a/pc/ice_server_parsing.cc b/pc/ice_server_parsing.cc index d9b4c39943..b7395c847e 100644 --- a/pc/ice_server_parsing.cc +++ b/pc/ice_server_parsing.cc @@ -237,7 +237,7 @@ static RTCErrorType ParseIceServerUrl( if (server.username.empty() || server.password.empty()) { // The WebRTC spec requires throwing an InvalidAccessError when username // or credential are ommitted; this is the native equivalent. - RTC_LOG(LS_ERROR) << "TURN server with empty username or password"; + RTC_LOG(LS_WARNING) << "TURN server with empty username or password"; return RTCErrorType::INVALID_PARAMETER; } // If the hostname field is not empty, then the server address must be @@ -251,7 +251,7 @@ static RTCErrorType ParseIceServerUrl( if (!IPFromString(address, &ip)) { // When hostname is set, the server address must be a // resolved ip address. - RTC_LOG(LS_ERROR) + RTC_LOG(LS_WARNING) << "IceServer has hostname field set, but URI does not " "contain an IP address."; return RTCErrorType::INVALID_PARAMETER; @@ -289,7 +289,7 @@ RTCErrorType ParseIceServers( if (!server.urls.empty()) { for (const std::string& url : server.urls) { if (url.empty()) { - RTC_LOG(LS_ERROR) << "Empty uri."; + RTC_LOG(LS_WARNING) << "Empty uri."; return RTCErrorType::SYNTAX_ERROR; } RTCErrorType err = @@ -306,7 +306,7 @@ RTCErrorType ParseIceServers( return err; } } else { - RTC_LOG(LS_ERROR) << "Empty uri."; + RTC_LOG(LS_WARNING) << "Empty uri."; return RTCErrorType::SYNTAX_ERROR; } } diff --git a/pc/peer_connection.cc b/pc/peer_connection.cc index 9843eeb7d9..de13d4ce02 100644 --- a/pc/peer_connection.cc +++ b/pc/peer_connection.cc @@ -1458,7 +1458,7 @@ RTCError PeerConnection::SetConfiguration( RTCErrorType parse_error = ParseIceServers(configuration.servers, &stun_servers, &turn_servers); if (parse_error != RTCErrorType::NONE) { - return RTCError(parse_error); + return RTCError(parse_error, "ICE server parse failed"); } // Add the turn logging id to all turn servers for (cricket::RelayServerConfig& turn_server : turn_servers) {