summaryrefslogtreecommitdiff
path: root/src/char_sql
diff options
context:
space:
mode:
authoramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-29 06:18:21 +0000
committeramber <amber@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-29 06:18:21 +0000
commitc1a8f6f0ac98a694e670bae4c8f74db126e0e8e8 (patch)
tree57a37cf82ced0b0b998b99e5dfdc27d62932420a /src/char_sql
parent7bfe35400c79bf97a5b0bed9f170912c37cf9452 (diff)
downloadhercules-c1a8f6f0ac98a694e670bae4c8f74db126e0e8e8.tar.gz
hercules-c1a8f6f0ac98a694e670bae4c8f74db126e0e8e8.tar.bz2
hercules-c1a8f6f0ac98a694e670bae4c8f74db126e0e8e8.tar.xz
hercules-c1a8f6f0ac98a694e670bae4c8f74db126e0e8e8.zip
Fixe compile time problems with our mixed C++/C conformance
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1328 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/char_sql')
-rw-r--r--src/char_sql/char.c7
-rw-r--r--src/char_sql/char.h2
-rw-r--r--src/char_sql/int_guild.c6
-rw-r--r--src/char_sql/inter.c2
4 files changed, 9 insertions, 8 deletions
diff --git a/src/char_sql/char.c b/src/char_sql/char.c
index ab20b893b..75bf663d0 100644
--- a/src/char_sql/char.c
+++ b/src/char_sql/char.c
@@ -67,6 +67,7 @@ char party_db[256] = "party";
char pet_db[256] = "pet";
char login_db[256] = "login";
char friend_db[256] = "friends";
+int db_use_sqldbs;
char login_db_account_id[32] = "account_id";
char login_db_level[32] = "level";
@@ -3138,7 +3139,7 @@ int char_lan_config_read(const char *lancfgName){
static int char_db_final(void *key,void *data,va_list ap)
{
- struct mmo_charstatus *p = data;
+ struct mmo_charstatus *p = (struct mmo_charstatus *) data;
if (p) aFree(p);
return 0;
}
@@ -3280,8 +3281,8 @@ int char_config_read(const char *cfgName) {
if (sscanf(line,"%[^:]: %[^\r\n]", w1, w2) != 2)
continue;
- remove_control_chars(w1);
- remove_control_chars(w2);
+ remove_control_chars((unsigned char *) w1);
+ remove_control_chars((unsigned char *) w2);
if (strcmpi(w1, "userid") == 0) {
memcpy(userid, w2, 24);
} else if (strcmpi(w1, "passwd") == 0) {
diff --git a/src/char_sql/char.h b/src/char_sql/char.h
index 74bb28cf1..ddd873374 100644
--- a/src/char_sql/char.h
+++ b/src/char_sql/char.h
@@ -71,7 +71,7 @@ extern char guild_storage_db[256];
extern char party_db[256];
extern char pet_db[256];
-int db_use_sqldbs; // added for sql item_db read for char server [Valaris]
+extern int db_use_sqldbs; // added for sql item_db read for char server [Valaris]
extern char login_db_level[32];
extern char login_db_account_id[32];
diff --git a/src/char_sql/int_guild.c b/src/char_sql/int_guild.c
index b5d20590a..5ec700a54 100644
--- a/src/char_sql/int_guild.c
+++ b/src/char_sql/int_guild.c
@@ -532,7 +532,7 @@ int inter_guildcastle_tosql(struct guild_castle *gc)
return 0;
}
//printf("[Guild Castle %02i]: Save...\n",gc->castle_id);
- gcopy = numdb_search(castle_db_,gc->castle_id);
+ gcopy = (struct guild_castle *) numdb_search(castle_db_,gc->castle_id);
if (gcopy == NULL) {
gcopy = (struct guild_castle *) aMalloc(sizeof(struct guild_castle));
numdb_insert(castle_db_, gc->castle_id, gcopy);
@@ -714,13 +714,13 @@ int guild_infoevent_db_final (void *k, void *data, va_list ap) { return 0; }
int guild_castleinfoevent_db_final (void *k, void *data, va_list ap) { return 0; }
int guild_db_final (void *k, void *data, va_list ap)
{
- struct guild *g = data;
+ struct guild *g = (struct guild *) data;
if (g) aFree(g);
return 0;
}
int castle_db_final (void *k, void *data, va_list ap)
{
- struct guild_castle *gc = data;
+ struct guild_castle *gc = (struct guild_castle *) data;
if (gc) aFree(gc);
return 0;
}
diff --git a/src/char_sql/inter.c b/src/char_sql/inter.c
index 13ce0acbe..1a2a2d751 100644
--- a/src/char_sql/inter.c
+++ b/src/char_sql/inter.c
@@ -300,7 +300,7 @@ int inter_init(const char *file)
// finalize
int wis_db_final (void *k, void *data, va_list ap) {
- struct WisData *p = data;
+ struct WisData *p = (struct WisData *) data;
if (p) aFree(p);
return 0;
}