aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDr Scofield2009-06-25 07:59:38 +0000
committerDr Scofield2009-06-25 07:59:38 +0000
commitfa060a7282c4db10256eadd30b3db46ba7085bc6 (patch)
tree446a472382def94b7c56b10d8e194468d889150a
parentmore efficient way of checking for already seen packets: (diff)
downloadopensim-SC_OLD-fa060a7282c4db10256eadd30b3db46ba7085bc6.zip
opensim-SC_OLD-fa060a7282c4db10256eadd30b3db46ba7085bc6.tar.gz
opensim-SC_OLD-fa060a7282c4db10256eadd30b3db46ba7085bc6.tar.bz2
opensim-SC_OLD-fa060a7282c4db10256eadd30b3db46ba7085bc6.tar.xz
commenting out rather expensive bits of GetClientInfo() --- the only
bit of GetClientInfo that is actually used seems to be userEP as part of the OSSL osGetAgentIP() script function. Now commented are the parts where we serialize and copy out the *entire* packet queue of the client (locking the packet handler in the process).
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs33
1 files changed, 20 insertions, 13 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
index 39922c0..a1a8e00 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
@@ -638,22 +638,29 @@ namespace OpenSim.Region.ClientStack.LindenUDP
638 public ClientInfo GetClientInfo() 638 public ClientInfo GetClientInfo()
639 { 639 {
640 ClientInfo info = new ClientInfo(); 640 ClientInfo info = new ClientInfo();
641 info.pendingAcks = m_PendingAcks;
642 info.needAck = new Dictionary<uint, byte[]>();
643 641
644 lock (m_NeedAck) 642 // nobody seems to even look at the following data. since
645 { 643 // it's a rather expensive operation (lock, serializing
646 foreach (uint key in m_NeedAck.Keys) 644 // packets, copying it into dictionary, etc) i've
647 info.needAck.Add(key, m_NeedAck[key].Packet.ToBytes()); 645 // commented out the expensive (but unwanted?) bits below
648 } 646 // (dr scofield, 2009-06-24)
649 647
650 LLQueItem[] queitems = m_PacketQueue.GetQueueArray(); 648 // info.pendingAcks = m_PendingAcks;
649 // info.needAck = new Dictionary<uint, byte[]>();
651 650
652 for (int i = 0; i < queitems.Length; i++) 651 // lock (m_NeedAck)
653 { 652 // {
654 if (queitems[i].Incoming == false) 653 // foreach (uint key in m_NeedAck.Keys)
655 info.out_packets.Add(queitems[i].Packet.ToBytes()); 654 // info.needAck.Add(key, m_NeedAck[key].Packet.ToBytes());
656 } 655 // }
656
657 // LLQueItem[] queitems = m_PacketQueue.GetQueueArray();
658
659 // for (int i = 0; i < queitems.Length; i++)
660 // {
661 // if (queitems[i].Incoming == false)
662 // info.out_packets.Add(queitems[i].Packet.ToBytes());
663 // }
657 664
658 info.sequence = m_Sequence; 665 info.sequence = m_Sequence;
659 666