Browse Source

- Fixed bug report 1436 (Auction)

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@12742 54d463be-8e91-2dee-dedb-b68131a5f0ec
zephyrus 17 years ago
parent
commit
edcd7e6d28
1 changed files with 9 additions and 3 deletions
  1. 9 3
      src/char_sql/int_auction.c

+ 9 - 3
src/char_sql/int_auction.c

@@ -276,11 +276,17 @@ static void mapif_parse_Auction_requestlist(int fd)
 			continue;
 
 		i++;
-		if( i > 5 ) { pages++; i = 0; }
-		if( page != pages ) continue;
+		if( i > 5 )
+		{ // Counting Pages of Total Results (5 Results per Page)
+			pages++;
+			i = 1; // First Result of This Page
+		}
+
+		if( page != pages )
+			continue; // This is not the requested Page
 
 		memcpy(WBUFP(buf, j * len), auction, len);
-		j++;
+		j++; // Found Results
 	}
 	iter->destroy(iter);