summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-08-15 09:24:45 +0000
committerultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-08-15 09:24:45 +0000
commit6b9866e3db9c1fe7a17b2ae40f4c746620b59569 (patch)
treea5be91c7cfb8061cd81660b2e793210a5b4cd54f /src
parent7e364e7e38b21a916d66715a4fd98d8f9b88e8aa (diff)
downloadhercules-6b9866e3db9c1fe7a17b2ae40f4c746620b59569.tar.gz
hercules-6b9866e3db9c1fe7a17b2ae40f4c746620b59569.tar.bz2
hercules-6b9866e3db9c1fe7a17b2ae40f4c746620b59569.tar.xz
hercules-6b9866e3db9c1fe7a17b2ae40f4c746620b59569.zip
small mapindex.c typo fix
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11014 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/common/mapindex.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/common/mapindex.c b/src/common/mapindex.c
index f169538f7..f2adc833c 100644
--- a/src/common/mapindex.c
+++ b/src/common/mapindex.c
@@ -118,13 +118,13 @@ unsigned short mapindex_name2id(const char* name)
#ifdef MAPINDEX_AUTOADD
if( mapindex_addmap(i,map_name) )
{
- ShowDebug("mapindex_name2id: Auto-added map \"%s\" to position %d\n", indexes[i], i);
+ ShowDebug("mapindex_name2id: Auto-added map \"%s\" to position %d\n", map_name, i);
return i;
}
- ShowWarning("mapindex_name2id: Failed to auto-add map \"%s\" to position %d!\n", name, i);
+ ShowWarning("mapindex_name2id: Failed to auto-add map \"%s\" to position %d!\n", map_name, i);
return 0;
#else
- ShowDebug("mapindex_name2id: Map \"%s\" not found in index list!\n", name);
+ ShowDebug("mapindex_name2id: Map \"%s\" not found in index list!\n", map_name);
return 0;
#endif
}
@@ -144,7 +144,7 @@ void mapindex_init(void)
char line[1024];
int last_index = -1;
int index;
- char map_name[1024]; // only MAP_NAME_LENGTH(_EXT) under safe conditions
+ char map_name[1024];
memset (&indexes, 0, sizeof (indexes));
fp=fopen(mapindex_cfgfile,"r");
@@ -157,7 +157,7 @@ void mapindex_init(void)
if(line[0] == '/' && line[1] == '/')
continue;
- switch (sscanf(line, "%s\t%d", map_name, &index))
+ switch (sscanf(line, "%1023s\t%d", map_name, &index))
{
case 1: //Map with no ID given, auto-assign
index = last_index+1;