Pārlūkot izejas kodu

Follow up 7f4a7ba

Signed-off-by: Cydh Ramdh <house.bad@gmail.com>
Cydh Ramdh 11 gadi atpakaļ
vecāks
revīzija
dc834fb39f
3 mainītis faili ar 5 papildinājumiem un 4 dzēšanām
  1. 2 2
      src/map/cashshop.c
  2. 1 1
      src/map/clif.c
  3. 2 1
      src/map/itemdb.c

+ 2 - 2
src/map/cashshop.c

@@ -88,7 +88,7 @@ static void cashshop_read_db_txt( void ){
 		}
 
 		while( fgets( line, sizeof( line ), fp ) ){
-			char *str[2], *p;
+			char *str[3], *p;
 			int i;
 			lines++;
 
@@ -103,7 +103,7 @@ static void cashshop_read_db_txt( void ){
 			if( *p == '\0' )
 				continue;
 
-			for( i = 0; i < 2; ++i ){
+			for( i = 0; i < 3; ++i ){
 				str[i] = p;
 				p = strchr( p, ',' );
 

+ 1 - 1
src/map/clif.c

@@ -17025,7 +17025,7 @@ void clif_ackworldinfo(struct map_session_data* sd) {
 	WFIFOHEAD(fd,packet_len(0x979));
 	WFIFOW(fd,0)=0x979;
 	//AID -> world name ?
-	safestrncpy((char*)WFIFOP(fd,2), '\0' /* World name */, 24);
+	safestrncpy((char*)WFIFOP(fd,2), "" /* World name */, 24);
 	safestrncpy((char*)WFIFOP(fd,26), sd->status.name, NAME_LENGTH);
 	WFIFOSET(fd,packet_len(0x979));
 }

+ 2 - 1
src/map/itemdb.c

@@ -664,7 +664,8 @@ static void itemdb_read_itemgroup_sub(const char* filename, bool silent)
 		int group_id = -1;
 		unsigned int j, prob = 1;
 		uint16 nameid, amt = 1, dur = 0;
-		char *str[9], *p, rand_group = 1, announced = 0, named = 0, bound = 0;
+		uint8 rand_group = 1;
+		char *str[9], *p, announced = 0, named = 0, bound = 0;
 		struct s_item_group_random *random = NULL;
 		struct s_item_group_db *group = NULL;
 		bool found = false;