diff options
author | DukePyrolator <DukePyrolator@5417fbe8-f217-4b02-8779-1006273d7864> | 2010-05-13 19:04:19 +0000 |
---|---|---|
committer | DukePyrolator <DukePyrolator@5417fbe8-f217-4b02-8779-1006273d7864> | 2010-05-13 19:04:19 +0000 |
commit | 0ab5111bda6babf8d0e5d4b990893aa4e49f080d (patch) | |
tree | f0ade0d1ae418932cf066120ce4f9c2b377741af /src/modules/mysql/db_mysql_write.cpp | |
parent | 6c56c238372bf7dbed58fe3dc3ea56d76e6f736b (diff) |
fixed crashbug in db_mysql_write on updating an empty greet message
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2954 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/modules/mysql/db_mysql_write.cpp')
-rw-r--r-- | src/modules/mysql/db_mysql_write.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/mysql/db_mysql_write.cpp b/src/modules/mysql/db_mysql_write.cpp index cd3a7458b..d1f587388 100644 --- a/src/modules/mysql/db_mysql_write.cpp +++ b/src/modules/mysql/db_mysql_write.cpp @@ -506,7 +506,7 @@ class DBMySQLWrite : public DBMySQL } else if (cmd == "GREET") { - query << "UPDATE `anope_ns_core` SET `greet` = " << mysqlpp::quote << nc->greet << " WHERE `display` = " << mysqlpp::quote << nc->display; + query << "UPDATE `anope_ns_core` SET `greet` = " << mysqlpp::quote << (nc->greet ? nc->greet : "") << " WHERE `display` = " << mysqlpp::quote << nc->display; ExecuteQuery(query); } else if (cmd == "KILL" || cmd == "SECURE" || cmd == "PRIVATE" || cmd == "MSG" || cmd == "HIDE" || cmd == "AUTOOP") |