From 81c63b0eed39432878f78727f60a1e7499645199 Mon Sep 17 00:00:00 2001 From: Yves-Alexis Perez Date: Fri, 11 Jul 2014 07:23:31 +0200 Subject: Imported Upstream version 5.2.0 --- src/libstrongswan/plugins/sqlite/Makefile.am | 2 +- src/libstrongswan/plugins/sqlite/Makefile.in | 8 ++++++-- src/libstrongswan/plugins/sqlite/sqlite_database.c | 10 ++++++---- 3 files changed, 13 insertions(+), 7 deletions(-) (limited to 'src/libstrongswan/plugins/sqlite') diff --git a/src/libstrongswan/plugins/sqlite/Makefile.am b/src/libstrongswan/plugins/sqlite/Makefile.am index 717d6350d..0a9b11d3c 100644 --- a/src/libstrongswan/plugins/sqlite/Makefile.am +++ b/src/libstrongswan/plugins/sqlite/Makefile.am @@ -2,7 +2,7 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/src/libstrongswan AM_CFLAGS = \ - -rdynamic + $(PLUGIN_CFLAGS) if MONOLITHIC noinst_LTLIBRARIES = libstrongswan-sqlite.la diff --git a/src/libstrongswan/plugins/sqlite/Makefile.in b/src/libstrongswan/plugins/sqlite/Makefile.in index 2cbacddf1..f7be0e43c 100644 --- a/src/libstrongswan/plugins/sqlite/Makefile.in +++ b/src/libstrongswan/plugins/sqlite/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.13.3 from Makefile.am. +# Makefile.in generated by automake 1.14.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2013 Free Software Foundation, Inc. @@ -266,6 +266,7 @@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ +OPENSSL_LIB = @OPENSSL_LIB@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ @@ -284,6 +285,7 @@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +PLUGIN_CFLAGS = @PLUGIN_CFLAGS@ PTHREADLIB = @PTHREADLIB@ PYTHON = @PYTHON@ PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ @@ -311,6 +313,7 @@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +aikgen_plugins = @aikgen_plugins@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -402,6 +405,7 @@ srcdir = @srcdir@ starter_plugins = @starter_plugins@ strongswan_conf = @strongswan_conf@ strongswan_options = @strongswan_options@ +swanctldir = @swanctldir@ sysconfdir = @sysconfdir@ systemdsystemunitdir = @systemdsystemunitdir@ t_plugins = @t_plugins@ @@ -416,7 +420,7 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/src/libstrongswan AM_CFLAGS = \ - -rdynamic + $(PLUGIN_CFLAGS) @MONOLITHIC_TRUE@noinst_LTLIBRARIES = libstrongswan-sqlite.la @MONOLITHIC_FALSE@plugin_LTLIBRARIES = libstrongswan-sqlite.la diff --git a/src/libstrongswan/plugins/sqlite/sqlite_database.c b/src/libstrongswan/plugins/sqlite/sqlite_database.c index 7b4767855..ec1ca1404 100644 --- a/src/libstrongswan/plugins/sqlite/sqlite_database.c +++ b/src/libstrongswan/plugins/sqlite/sqlite_database.c @@ -101,13 +101,15 @@ static sqlite3_stmt* run(private_sqlite_database_t *this, char *sql, case DB_TEXT: { const char *text = va_arg(*args, const char*); - res = sqlite3_bind_text(stmt, i, text, -1, SQLITE_STATIC); + res = sqlite3_bind_text(stmt, i, text, -1, + SQLITE_TRANSIENT); break; } case DB_BLOB: { chunk_t c = va_arg(*args, chunk_t); - res = sqlite3_bind_blob(stmt, i, c.ptr, c.len, SQLITE_STATIC); + res = sqlite3_bind_blob(stmt, i, c.ptr, c.len, + SQLITE_TRANSIENT); break; } case DB_DOUBLE: @@ -365,7 +367,7 @@ static bool finalize_transaction(private_sqlite_database_t *this, return TRUE; } -METHOD(database_t, commit, bool, +METHOD(database_t, commit_, bool, private_sqlite_database_t *this) { return finalize_transaction(this, FALSE); @@ -429,7 +431,7 @@ sqlite_database_t *sqlite_database_create(char *uri) .query = _query, .execute = _execute, .transaction = _transaction, - .commit = _commit, + .commit = _commit_, .rollback = _rollback, .get_driver = _get_driver, .destroy = _destroy, -- cgit v1.2.3