From f0040493d1657463bdd4425e022588f7d0ac6296 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Sun, 25 Aug 2002 08:03:50 +0000 Subject: [PATCH] removing SQL for info command --- src/common/modules/infocmd.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/common/modules/infocmd.c b/src/common/modules/infocmd.c index ad8f3cb32..55302c220 100644 --- a/src/common/modules/infocmd.c +++ b/src/common/modules/infocmd.c @@ -48,8 +48,10 @@ info_name(const char * str, void * data, const char * cmd) const char * name = sqlquote(igetstrtoken(str)); if (sqlstream!=NULL) { +#ifdef SQLOUTPUT fprintf(sqlstream, "UPDATE users SET firstname = '%s' WHERE id = %u;\n", name, f->unique_id); +#endif } } @@ -61,8 +63,10 @@ info_address(const char * str, void * data, const char * cmd) const char * address = sqlquote(igetstrtoken(str)); if (sqlstream!=NULL) { +#ifdef SQLOUTPUT fprintf(sqlstream, "UPDATE users SET address = '%s' WHERE id = %u;\n", address, f->unique_id); +#endif } } @@ -74,8 +78,10 @@ info_phone(const char * str, void * data, const char * cmd) const char * phone = sqlquote(igetstrtoken(str)); if (sqlstream!=NULL) { +#ifdef SQLOUTPUT fprintf(sqlstream, "UPDATE users SET phone = '%s' WHERE id = %u;\n", phone, f->unique_id); +#endif } } @@ -92,11 +98,13 @@ info_vacation(const char * str, void * data, const char * cmd) struct tm end = *localtime(&end_time); if (sqlstream!=NULL) { +#ifdef SQLOUTPUT fprintf(sqlstream, "UPDATE factions SET vacation = '%s' WHERE id = '%s';\n", email, itoa36(f->no)); fprintf(sqlstream, "UPDATE factions SET vacation_start = '%04d-%02d-%02d' WHERE id = '%s';\n", start.tm_year, start.tm_mon, start.tm_mday, itoa36(f->no)); fprintf(sqlstream, "UPDATE factions SET vacation_end = '%04d-%02d-%02d' WHERE id = '%s';\n", end.tm_year, end.tm_mon, end.tm_mday, itoa36(f->no)); +#endif } }