Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Server Code Submissions

Reply
 
Thread Tools Display Modes
  #1  
Old 05-03-2010, 03:49 PM
Akkadius's Avatar
Akkadius
Administrator
 
Join Date: Feb 2009
Location: MN
Posts: 2,071
Default Saylink's Crashing Zone on No Target Fix

Now I had a problem on my server which obviously isn't released yet, but with the amount saylinks that we have that aren't silent causing zone crashes were blowing up on recent revisions.

This is just a general fix that Secrets helped with and now saylinks no longer crash zones without a target, and of course still function normally.

Code:
Index: client.cpp
===================================================================
--- client.cpp	(revision 1451)
+++ client.cpp	(working copy)
@@ -737,7 +737,8 @@
 	if (targetname == NULL) {
 		targetname = (!GetTarget()) ? NULL : GetTarget()->GetName();
 	}
-
+if(targetname)
+{
 	if(RuleB(Chat, EnableAntiSpam))
 	{
 		if(strcmp(targetname, "discard") != 0)
@@ -758,7 +759,7 @@
 				
 				if(RuleI(Chat, MinStatusToBypassAntiSpam) <= Admin())
 					AllowedMessages = 10000;
-
+				
 				AttemptedMessages++;
 				if(AttemptedMessages > AllowedMessages)
 				{
@@ -782,6 +783,7 @@
 			}
 		}
 	}
+	}
 
 	switch(chan_num)
 	{
Reply With Quote
  #2  
Old 05-03-2010, 09:22 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

I briefly looked this over, but I am not seeing where the crash would be caused from the code before making that change.

Saylinks just send this from client_packet.cpp
Code:
this->ChannelMessageReceived(8, 0, 100, response);
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #3  
Old 05-04-2010, 11:37 AM
Akkadius's Avatar
Akkadius
Administrator
 
Join Date: Feb 2009
Location: MN
Posts: 2,071
Default

I don't know what to say then, I will probably continue to use those 3 lines until it stops crashing the zones when not targeted.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 09:12 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3