summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-12-27 12:44:53 +0000
committeramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-12-27 12:44:53 +0000
commitb5667de306377d62cf511f4173e396da7bf2cc26 (patch)
tree7b98e76266d8faaae71fc0593d3aca759d8eb7fa
parent40ccd9330910f3b94ad1266014c5370ebb3909ac (diff)
downloadhercules-b5667de306377d62cf511f4173e396da7bf2cc26.tar.gz
hercules-b5667de306377d62cf511f4173e396da7bf2cc26.tar.bz2
hercules-b5667de306377d62cf511f4173e396da7bf2cc26.tar.xz
hercules-b5667de306377d62cf511f4173e396da7bf2cc26.zip
Fix
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@816 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog.txt2
-rw-r--r--src/char_sql/int_guild.c6
2 files changed, 6 insertions, 2 deletions
diff --git a/Changelog.txt b/Changelog.txt
index 61dc1a64d..f49ccce23 100644
--- a/Changelog.txt
+++ b/Changelog.txt
@@ -1,5 +1,7 @@
Date Added
12/27
+ * Fixed a bug in the guild_castle persistance code
+ in char_sql. What was I smoking? (SVN: 816) [MouseJstr]
* Corrected a bad error in itemdb_read_itemslottable [celest]
* Corrected wrong logging of text in int_guild.c, thanks to Alex14 [celest]
* Summoned monsters will not give exp and items [celest]
diff --git a/src/char_sql/int_guild.c b/src/char_sql/int_guild.c
index 5d79800ab..1949947f5 100644
--- a/src/char_sql/int_guild.c
+++ b/src/char_sql/int_guild.c
@@ -48,6 +48,8 @@ int _erase_guild(void *key, void *data, va_list ap) {
free(castle);
db_erase(castle_db_, key);
}
+
+ return 0;
}
// Save guild into sql
@@ -162,7 +164,7 @@ int inter_guild_tosql(struct guild *g,int flag)
if(mysql_query(&mysql_handle, tmp_sql) ) {
printf("DB server Error (delete `guild_castle`)- %s\n", mysql_error(&mysql_handle) );
}
- db_foreach(_guild_castle_, _erase_guild, g->guild_id);
+ db_foreach(castle_db_, _erase_guild, g->guild_id);
}
}
@@ -1333,7 +1335,7 @@ int mapif_parse_BreakGuild(int fd,int guild_id)
printf("DB server Error (delete `guild_position`)- %s\n", mysql_error(&mysql_handle) );
}
- db_foreach(_guild_castle_, _erase_guild, guild_id);
+ db_foreach(castle_db_, _erase_guild, guild_id);
//printf("- Update guild %d of char\n",guild_id);
sprintf(tmp_sql, "UPDATE `%s` SET `guild_id`='0' WHERE `guild_id`='%d'",char_db, guild_id);