From 1912215c40e1ea1f89710306c6f3d23e303d433a Mon Sep 17 00:00:00 2001 From: "Justin Clark-Casey (justincc)" Date: Thu, 12 Jul 2012 23:29:57 +0100 Subject: [PATCH] Remove IClientAPI.GetClientEP() in favour of existing identical IClientAPI.RemoteEndpoint. --- OpenSim/Framework/IClientAPI.cs | 1 - OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | 5 ----- .../Agent/InternetRelayClientView/Server/IRCClientView.cs | 5 ----- OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | 5 ----- .../ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 8 ++------ OpenSim/Tests/Common/Mock/TestClient.cs | 5 ----- 6 files changed, 2 insertions(+), 27 deletions(-) diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 880d5bf820..4ca1031109 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs @@ -1354,7 +1354,6 @@ namespace OpenSim.Framework void SendBlueBoxMessage(UUID FromAvatarID, String FromAvatarName, String Message); void SendLogoutPacket(); - EndPoint GetClientEP(); // WARNING WARNING WARNING // diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index 8e59e83f0a..4cbd1565dc 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -11874,11 +11874,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP m_udpClient.SetClientInfo(info); } - public EndPoint GetClientEP() - { - return m_userEndPoint; - } - #region Media Parcel Members public void SendParcelMediaCommand(uint flags, ParcelMediaCommandEnum command, float time) diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index b2fa9db5ec..d133a77174 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs @@ -1436,11 +1436,6 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server Disconnect(); } - public EndPoint GetClientEP() - { - return null; - } - public ClientInfo GetClientInfo() { return new ClientInfo(); diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 1e1f5c1d54..2fb5bfc40a 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs @@ -895,11 +895,6 @@ namespace OpenSim.Region.OptionalModules.World.NPC { } - public EndPoint GetClientEP() - { - return null; - } - public ClientInfo GetClientInfo() { return null; diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 5dc35c0e3a..85ee8e5ea8 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs @@ -872,13 +872,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api if (World.Entities.ContainsKey((UUID)agent) && World.Entities[avatarID] is ScenePresence) { ScenePresence target = (ScenePresence)World.Entities[avatarID]; - EndPoint ep = target.ControllingClient.GetClientEP(); - if (ep is IPEndPoint) - { - IPEndPoint ip = (IPEndPoint)ep; - return ip.Address.ToString(); - } + return target.ControllingClient.RemoteEndPoint.Address.ToString(); } + // fall through case, just return nothing return ""; } diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 9c0ad3cc5b..420370434e 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs @@ -968,11 +968,6 @@ namespace OpenSim.Tests.Common.Mock { } - public EndPoint GetClientEP() - { - return null; - } - public ClientInfo GetClientInfo() { return null;