Added check to prevent crashing on logmes with no player attached (bugreport:1648).
git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@12815 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
625f9f62fd
commit
06f9538ece
@ -5,6 +5,8 @@ IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
|||||||
|
|
||||||
|
|
||||||
2008/06/12
|
2008/06/12
|
||||||
|
* Added check to prevent crashing on logmes with no player attached
|
||||||
|
(bugreport:1648) [ultramage]
|
||||||
* Added support for skill names to script commands: [FlavioJS]
|
* Added support for skill names to script commands: [FlavioJS]
|
||||||
- skill, addtoskill, guildskill, getskilllv, getgdskilllv, itemskill,
|
- skill, addtoskill, guildskill, getskilllv, getgdskilllv, itemskill,
|
||||||
petskillattack, petskillattack2, petskillsupport, skilleffect,
|
petskillattack, petskillattack2, petskillsupport, skilleffect,
|
||||||
|
@ -11282,9 +11282,17 @@ BUILDIN_FUNC(getmapxy)
|
|||||||
BUILDIN_FUNC(logmes)
|
BUILDIN_FUNC(logmes)
|
||||||
{
|
{
|
||||||
const char *str;
|
const char *str;
|
||||||
if (log_config.npc <= 0 ) return 0;
|
TBL_PC* sd;
|
||||||
|
|
||||||
|
if( log_config.npc <= 0 )
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
sd = script_rid2sd(st);
|
||||||
|
if( sd == NULL )
|
||||||
|
return 1;
|
||||||
|
|
||||||
str = script_getstr(st,2);
|
str = script_getstr(st,2);
|
||||||
log_npc(script_rid2sd(st),str);
|
log_npc(sd,str);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user