From 277be5ffb90645f37494f08264b64e6bfa133732 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 29 Nov 2020 15:02:31 +0100 Subject: [PATCH] Use Xenial version of odbc-postgresql package Travis hosts use PostgreSQL PPA which is problematic for a few reasons: 1. We don't actually test in the same environment as most SOCI users, who would just use the standard Ubuntu repositories and not this PPA. 2. The environment is not even stable, e.g. recently the version of psqlodbc has changed from 12 to 13 in Travis builds, breaking them due to new leak reports from ASAN. 3. We don't have debug symbols for these packages as the PPA doesn't provide them and the ones from Ubuntu repositories don't match. This prevents us from even creating precise suppressions for ASAN. Solve all these problems at once by just sticking to the stock Xenial version, which doesn't even trigger any leak reports, so there is nothing to suppress any more and the changes of 457ec97e (Suppress reports about memory leaks in PostgreSQL ODBC test, 2020-03-29) can be reverted. --- .travis.yml | 3 +++ scripts/suppress_odbc.txt | 6 ------ scripts/travis/before_install_odbc.sh | 2 +- scripts/travis/script_odbc.sh | 2 +- 4 files changed, 5 insertions(+), 8 deletions(-) delete mode 100644 scripts/suppress_odbc.txt diff --git a/.travis.yml b/.travis.yml index 96c5dea7..2d1c0eb8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,9 @@ # # Copyright (c) 2013 Mateusz Loskot # + +# When changing this, search for "xenial" in scripts/travis and update +# references to it there too. dist: xenial sudo: required diff --git a/scripts/suppress_odbc.txt b/scripts/suppress_odbc.txt deleted file mode 100644 index e264f482..00000000 --- a/scripts/suppress_odbc.txt +++ /dev/null @@ -1,6 +0,0 @@ -# This is a suppression file for LeakSanitizer when running ODBC tests. - -# Unfortunately there is a leak from psqlodbca.so for which ASAN doesn't show -# any stack at all, so we have no choice but to suppress all leaks from this -# library, even though it could easily hide real problems. -leak:psqlodbca.so diff --git a/scripts/travis/before_install_odbc.sh b/scripts/travis/before_install_odbc.sh index 1226505b..48bf2c92 100755 --- a/scripts/travis/before_install_odbc.sh +++ b/scripts/travis/before_install_odbc.sh @@ -8,4 +8,4 @@ source ${TRAVIS_BUILD_DIR}/scripts/travis/common.sh sudo apt-get install -qq \ tar bzip2 \ unixodbc-dev \ - odbc-postgresql + odbc-postgresql/xenial diff --git a/scripts/travis/script_odbc.sh b/scripts/travis/script_odbc.sh index 6c9c5169..9865fec2 100755 --- a/scripts/travis/script_odbc.sh +++ b/scripts/travis/script_odbc.sh @@ -19,4 +19,4 @@ run_make # Exclude the tests which can't be run due to the absence of ODBC drivers (MS # SQL and MySQL). -LSAN_OPTIONS=suppressions=${TRAVIS_BUILD_DIR}/scripts/suppress_odbc.txt run_test -E 'soci_odbc_test_m.sql' +run_test -E 'soci_odbc_test_m.sql'