From a8bc3d7645114789c1dff49e6819981cba704435 Mon Sep 17 00:00:00 2001 From: Daniel De Graaf Date: Wed, 4 Aug 2010 17:02:15 -0400 Subject: Fix $md5pass and $sha256pass in SQL queries --- src/modules/extra/m_mysql.cpp | 2 +- src/modules/extra/m_pgsql.cpp | 2 +- src/modules/extra/m_sqlite3.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/modules') diff --git a/src/modules/extra/m_mysql.cpp b/src/modules/extra/m_mysql.cpp index 236cb4349..9a97c10bf 100644 --- a/src/modules/extra/m_mysql.cpp +++ b/src/modules/extra/m_mysql.cpp @@ -344,7 +344,7 @@ class SQLConnection : public SQLProvider { std::string field; i++; - while (i < q.length() && isalpha(q[i])) + while (i < q.length() && isalnum(q[i])) field.push_back(q[i++]); i--; diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp index 655007ea3..0ea1e0b6a 100644 --- a/src/modules/extra/m_pgsql.cpp +++ b/src/modules/extra/m_pgsql.cpp @@ -429,7 +429,7 @@ restart: { std::string field; i++; - while (i < q.length() && isalpha(q[i])) + while (i < q.length() && isalnum(q[i])) field.push_back(q[i++]); i--; diff --git a/src/modules/extra/m_sqlite3.cpp b/src/modules/extra/m_sqlite3.cpp index b3bb5a51b..3809ac738 100644 --- a/src/modules/extra/m_sqlite3.cpp +++ b/src/modules/extra/m_sqlite3.cpp @@ -174,7 +174,7 @@ class SQLConn : public SQLProvider { std::string field; i++; - while (i < q.length() && isalpha(q[i])) + while (i < q.length() && isalnum(q[i])) field.push_back(q[i++]); i--; -- cgit v1.2.3