Jump to content
  • 0

Server freeze and map_addblock question


ragazel

Question


  • Group:  Members
  • Topic Count:  4
  • Topics Per Day:  0.00
  • Content Count:  10
  • Reputation:   0
  • Joined:  07/26/13
  • Last Seen:  

Hello everyone, I need a little help again   /wah

 

lately my server did a random freeze (not crashing, so I cant get any dump), and its only happening when WoE is running.

 

I try to find what causing server freeze, but I only get these error:

 

cK3LeIP.png

 

However, server didnt freeze while this error appearing, but its happened in a random time after this error happening (yet the map server log didnt show any error beside this, not even crash)

 

While I think this is not a problem for server freeze, Im just curious what causing this error and maybe this is good to be a start point

 

I want to ask is my modification to source is safe for server or not (or maybe get a few improvement).

 

Here are my modification (warning ugly code, since I just know a little about programming)

 

map.c at map_addblock function

char* bltype = "";
switch(bl->type){
		case BL_NUL: bltype="NUL";
			break;
		case BL_PC: bltype="PC";
			break;
		case BL_MOB: bltype="MOB";
			break;
		case BL_PET: bltype="PET";
			break;
		case BL_HOM: bltype="HOM";
			break;
		case BL_MER: bltype="MER";
			break;
		case BL_ITEM: bltype="ITEM";
			break;
		case BL_SKILL: bltype="SKILL";
			break;
		case BL_NPC: bltype="NPC";
			break;
		case BL_CHAT: bltype="CHAT";
			break;
		case BL_ELEM: bltype="ELEM";
			break;
	}

and modified a bit for out of bound error function

if( x < 0 || x >= map[m].xs || y < 0 || y >= map[m].ys )
{
ShowError("map_addblock: out-of-bounds coordinates (\"%s\",%d,%d), map is %dx%d\n", map[m].name, x, y, map[m].xs, map[m].ys);
return 1;
}

to

if( x < 0 || x >= map[m].xs || y < 0 || y >= map[m].ys )
{
ShowError("map_addblock: out-of-bounds coordinates (\"%s\",%d,%d), map is %dx%d, type is %s\n", map[m].name, x, y, map[m].xs, map[m].ys, bltype);
return 1;
}

Of course I will happy if someone know why server did a random freeze,

but since I have no clue what causing the freeze beside this error, at least I want to start with what type causing the error.

 

thank you and sorry for bad english, hope what I mean is explained correctly and clear enough  /ok

Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...