commit 9b0286684f31ddcef056f61cac336155c62130e9 Author: Nathanael D. Noblet <nathan...@gnat.ca> Date: Wed May 15 09:51:14 2013 -0600
fixed bugs #657357 and #954345 dspam-cron | 48 ++---------------------------------------------- dspam.spec | 7 ++++++- 2 files changed, 8 insertions(+), 47 deletions(-) --- diff --git a/dspam-cron b/dspam-cron index 26e0ae3..1f08bb3 100644 --- a/dspam-cron +++ b/dspam-cron @@ -239,7 +239,7 @@ clean_pgsql_drv() { [ -n "${PgSQLServer}" -a -n "${PgSQLUser}" -a -n "${PgSQLDb}" ] then DSPAM_PgSQL_PURGE_SQL= - DSPAM_PgSQL_PURGE_SQL_FILES="pgsql_pe-purge" + DSPAM_PgSQL_PURGE_SQL_FILES="pgsql/purge-pe pgsql/purge" # # We first search for the purge scripts in the directory the user has @@ -347,7 +347,7 @@ clean_sqlite3_drv() { then DSPAM_SQLite3_PURGE_SQL="" [ -f "${DSPAM_CONFIGDIR}/config/sqlite3_purge.sql" ] && DSPAM_SQLite3_PURGE_SQL="${DSPAM_CONFIGDIR}/config/sqlite3_purge.sql" - [ -f "${DSPAM_CONFIGDIR}/sqlite3_purge.sql" ] && DSPAM_SQLite3_PURGE_SQL="${DSPAM_CONFIGDIR}/sqlite3_purge.sql" + [ -f "${DSPAM_PURGE_SCRIPT_DIR}/sqlite3/purge-3.sql" ] && DSPAM_SQLite3_PURGE_SQL="${DSPAM_PURGE_SCRIPT_DIR}/sqlite3/purge-3.sql" if [ -z "${DSPAM_SQLite3_PURGE_SQL}" ] then @@ -377,47 +377,6 @@ clean_sqlite3_drv() { # -# Function to clean DSPAM SQLite < 3.0 data -# -clean_sqlite_drv() { - # - # SQLite - # - [ "${VERBOSE}" = "true" ] && echo "Running SQLite v2 storage driver data cleanup" - if [ "${USE_SQL_PURGE}" = "true" ] - then - DSPAM_SQLite_PURGE_SQL="" - [ -f "${DSPAM_CONFIGDIR}/config/sqlite_purge.sql" ] && DSPAM_SQLite_PURGE_SQL="${DSPAM_CONFIGDIR}/config/sqlite_purge.sql" - [ -f "${DSPAM_CONFIGDIR}/sqlite_purge.sql" ] && DSPAM_SQLite_PURGE_SQL="${DSPAM_CONFIGDIR}/sqlite_purge.sql" - - if [ -z "${DSPAM_SQLite_PURGE_SQL}" ] - then - echo "Can not run SQLite purge script:" - echo " No sqlite_purge SQL script found" - return 1 - fi - - if [ ! -e "${SQLITE_BIN_DIR}/sqlite" ] - then - echo "Can not run SQLite purge script:" - echo " ${SQLITE_BIN_DIR}/sqlite does not exist" - return 1 - fi - - # Run the SQLite purge script and vacuum - find "${DSPAM_HOMEDIR}" -name "*.sdb" -print | while read name - do - ${SQLITE_BIN_DIR}/sqlite "${name}" < "${DSPAM_SQLite_PURGE_SQL}" >/dev/null - # Enable the next line if you don't vacuum in the purge script - # echo "vacuum;" | ${SQLITE_BIN_DIR}/sqlite "${name}" >/dev/null - done 1>/dev/null 2>&1 - return 0 - fi - -} - - -# # Use a lock file to prevent multiple runs at the same time # DSPAM_CRON_LOCKFILE="/var/run/$(basename $0 .sh).pid" @@ -737,9 +696,6 @@ if ( set -o noclobber; echo "$$" > "${DSPAM_CRON_LOCKFILE}") 2> /dev/null; then sqlite3_drv) clean_sqlite3_drv ;; - sqlite_drv) - clean_sqlite_drv - ;; *) RUN_FULL_DSPAM_CLEAN="YES" echo "Unknown storage ${foo} driver" diff --git a/dspam.spec b/dspam.spec index 25754e1..d0e2804 100644 --- a/dspam.spec +++ b/dspam.spec @@ -7,11 +7,12 @@ %global dspam_mode 2511 %global dspam_web_docroot %{_localstatedir}/www/dspam %global __perl_requires %{SOURCE99} +%global _hardened_build 1 Summary: A library and Mail Delivery Agent for Bayesian SPAM filtering Name: dspam Version: 3.10.2 -Release: 5%{?dist} +Release: 6%{?dist} License: GPLv2 Group: System Environment/Daemons Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz @@ -367,6 +368,10 @@ exit 0 %config(noreplace) %{_sysconfdir}/httpd/conf.d/dspam-web.conf %changelog +* Wed May 15 2013 Nathanael Noblet <nathan...@gnat.ca> - 3.10.2-6 +- set hardened build to add PIE option since dspam can be long running bug #954345 +- properly fixes #657357 - PostgreSQL purge script works + * Thu Nov 29 2012 Nathanael Noblet <nathan...@gnat.ca> - 3.10.2-5 - Fix dspam-web.conf file to work with httpd 2.4 and 2.2 bug#871396 -- Fedora Extras Perl SIG http://www.fedoraproject.org/wiki/Extras/SIGs/Perl perl-devel mailing list perl-de...@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/perl-devel