aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
diff options
context:
space:
mode:
authorMelanie2009-10-01 21:08:17 +0100
committerMelanie2009-10-01 21:08:17 +0100
commit5e9da4daabc49250af9c0ec810b1290c74bad885 (patch)
tree532821dc84556e6f395545a027fdfcfddf7c8bda /OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
parentFixing LLClientView memory leak (diff)
downloadopensim-SC_OLD-5e9da4daabc49250af9c0ec810b1290c74bad885.zip
opensim-SC_OLD-5e9da4daabc49250af9c0ec810b1290c74bad885.tar.gz
opensim-SC_OLD-5e9da4daabc49250af9c0ec810b1290c74bad885.tar.bz2
opensim-SC_OLD-5e9da4daabc49250af9c0ec810b1290c74bad885.tar.xz
Add OnQueueEmpty event to the packet layers. No user functinality yet
Diffstat (limited to 'OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
index 67ece75..801e0c5 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs
@@ -129,6 +129,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
129 // 129 //
130 public event PacketStats OnPacketStats; 130 public event PacketStats OnPacketStats;
131 public event PacketDrop OnPacketDrop; 131 public event PacketDrop OnPacketDrop;
132 public event QueueEmpty OnQueueEmpty;
132 133
133 134
134 //private SynchronizeClientHandler m_SynchronizeClient = null; 135 //private SynchronizeClientHandler m_SynchronizeClient = null;
@@ -172,6 +173,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
172 173
173 m_PacketQueue = new LLPacketQueue(client.AgentId, userSettings); 174 m_PacketQueue = new LLPacketQueue(client.AgentId, userSettings);
174 175
176 m_PacketQueue.OnQueueEmpty += TriggerOnQueueEmpty;
177
175 m_AckTimer.Elapsed += AckTimerElapsed; 178 m_AckTimer.Elapsed += AckTimerElapsed;
176 m_AckTimer.Start(); 179 m_AckTimer.Start();
177 } 180 }
@@ -769,6 +772,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP
769 handlerPacketDrop(packet, id); 772 handlerPacketDrop(packet, id);
770 } 773 }
771 774
775 private void TriggerOnQueueEmpty(ThrottleOutPacketType queue)
776 {
777 QueueEmpty handlerQueueEmpty = OnQueueEmpty;
778
779 if (handlerQueueEmpty == null)
780 return;
781
782 handlerQueueEmpty(queue);
783 }
784
772 // Convert the packet to bytes and stuff it onto the send queue 785 // Convert the packet to bytes and stuff it onto the send queue
773 // 786 //
774 public void ProcessOutPacket(LLQueItem item) 787 public void ProcessOutPacket(LLQueItem item)