diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/Makefile.am | 2 | ||||
-rw-r--r-- | src/modules/Makefile.in | 6 | ||||
-rw-r--r-- | src/modules/UserBackendMysql.cpp | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/Makefile.am b/src/modules/Makefile.am index 93b54b3..eb95034 100644 --- a/src/modules/Makefile.am +++ b/src/modules/Makefile.am @@ -31,7 +31,7 @@ SystemBackendProc_la_SOURCES = SystemBackendProc.cpp SystemBackendProc_la_LDFLAGS = $(static_ldflags) -export-symbols-regex '^SystemBackendProc_LTX_' UserBackendMysql_la_SOURCES = UserBackendMysql.cpp -UserBackendMysql_la_LIBADD = $(MYSQL_LDFLAGS) $(pcrecpp_LIBS) +UserBackendMysql_la_LIBADD = $(MYSQL_LDFLAGS) $(BOOST_REGEX_LIB) UserBackendMysql_la_LDFLAGS = $(default_ldflags) -export-symbols-regex '^UserBackendMysql_LTX_' noinst_HEADERS = FileLogger.h SystemBackendPosix.h SystemBackendProc.h UserBackendMysql.h diff --git a/src/modules/Makefile.in b/src/modules/Makefile.in index 8dc9810..174cfc0 100644 --- a/src/modules/Makefile.in +++ b/src/modules/Makefile.in @@ -42,6 +42,7 @@ DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/argz.m4 \ $(top_srcdir)/m4/ax_boost_base.m4 \ + $(top_srcdir)/m4/ax_boost_regex.m4 \ $(top_srcdir)/m4/ax_boost_signals.m4 \ $(top_srcdir)/m4/ax_boost_thread.m4 \ $(top_srcdir)/m4/ax_lib_mysql.m4 $(top_srcdir)/m4/libtool.m4 \ @@ -124,6 +125,7 @@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_LDFLAGS = @BOOST_LDFLAGS@ +BOOST_REGEX_LIB = @BOOST_REGEX_LIB@ BOOST_SIGNALS_LIB = @BOOST_SIGNALS_LIB@ BOOST_THREAD_LIB = @BOOST_THREAD_LIB@ CC = @CC@ @@ -248,8 +250,6 @@ ltdl_LTLIBOBJS = @ltdl_LTLIBOBJS@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ -pcrecpp_CFLAGS = @pcrecpp_CFLAGS@ -pcrecpp_LIBS = @pcrecpp_LIBS@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ @@ -277,7 +277,7 @@ SystemBackendPosix_la_LDFLAGS = $(static_ldflags) -export-symbols-regex '^System SystemBackendProc_la_SOURCES = SystemBackendProc.cpp SystemBackendProc_la_LDFLAGS = $(static_ldflags) -export-symbols-regex '^SystemBackendProc_LTX_' UserBackendMysql_la_SOURCES = UserBackendMysql.cpp -UserBackendMysql_la_LIBADD = $(MYSQL_LDFLAGS) $(pcrecpp_LIBS) +UserBackendMysql_la_LIBADD = $(MYSQL_LDFLAGS) $(BOOST_REGEX_LIB) UserBackendMysql_la_LDFLAGS = $(default_ldflags) -export-symbols-regex '^UserBackendMysql_LTX_' noinst_HEADERS = FileLogger.h SystemBackendPosix.h SystemBackendProc.h UserBackendMysql.h all: all-am diff --git a/src/modules/UserBackendMysql.cpp b/src/modules/UserBackendMysql.cpp index da5126a..af25f5b 100644 --- a/src/modules/UserBackendMysql.cpp +++ b/src/modules/UserBackendMysql.cpp @@ -28,7 +28,7 @@ #include <sstream> #include <boost/bind.hpp> -#include <pcrecpp.h> +#include <boost/regex.hpp> #define init UserBackendMysql_LTX_init #define deinit UserBackendMysql_LTX_deinit @@ -170,7 +170,7 @@ bool UserBackendMysql::getUserInfo(unsigned long uid, const boost::function1<voi tmp << uid; tmp << '"'; - pcrecpp::RE("\\{ID\\}").GlobalReplace(tmp.str(), &query); + query = boost::regex_replace(query, boost::regex("\\{ID\\}"), tmp.str(), boost::match_default); mysql_real_query(mysql, query.c_str(), query.length()); MYSQL_RES *result = mysql_use_result(mysql); |