parquet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jul...@apache.org
Subject parquet-cpp git commit: PARQUET-513: Fail build if valgrind finds error during ctest, fix a core dump
Date Tue, 09 Feb 2016 01:37:09 GMT
Repository: parquet-cpp
Updated Branches:
  refs/heads/master c50f8f20a -> f3dbd5a4e


PARQUET-513: Fail build if valgrind finds error during ctest, fix a core dump

Also adds an option to use ccache with a custom gcc toolchain.

Fixes an improper memory access stemming from a unit test that had a wrong parameter.

Author: Wes McKinney <wes@cloudera.com>

Closes #42 from wesm/PARQUET-513 and squashes the following commits:

43df9e7 [Wes McKinney] Fix core dump from unit test bug
b46c617 [Wes McKinney] Fail build if valgrind finds error during ctest


Project: http://git-wip-us.apache.org/repos/asf/parquet-cpp/repo
Commit: http://git-wip-us.apache.org/repos/asf/parquet-cpp/commit/f3dbd5a4
Tree: http://git-wip-us.apache.org/repos/asf/parquet-cpp/tree/f3dbd5a4
Diff: http://git-wip-us.apache.org/repos/asf/parquet-cpp/diff/f3dbd5a4

Branch: refs/heads/master
Commit: f3dbd5a4ef9dd18e36a54fe0efff20ef023a0b73
Parents: c50f8f2
Author: Wes McKinney <wes@cloudera.com>
Authored: Mon Feb 8 17:37:05 2016 -0800
Committer: Julien Le Dem <julien@dremio.com>
Committed: Mon Feb 8 17:37:05 2016 -0800

----------------------------------------------------------------------
 .travis.yml                                 | 2 +-
 CMakeLists.txt                              | 7 +++++++
 src/parquet/schema/schema-converter-test.cc | 2 +-
 3 files changed, 9 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/parquet-cpp/blob/f3dbd5a4/.travis.yml
----------------------------------------------------------------------
diff --git a/.travis.yml b/.travis.yml
index 71a7767..a860bd7 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -42,6 +42,6 @@ script:
 - make
 - >
   if [ $TRAVIS_OS_NAME == linux ]; then
-    valgrind --tool=memcheck --leak-check=yes ctest;
+    valgrind --tool=memcheck --leak-check=yes --error-exitcode=1 ctest;
   fi
 - make lint

http://git-wip-us.apache.org/repos/asf/parquet-cpp/blob/f3dbd5a4/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 44c5bfa..6d150e2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -24,6 +24,13 @@ if (NOT "$ENV{PARQUET_GCC_ROOT}" STREQUAL "")
   set(CMAKE_CXX_COMPILER ${GCC_ROOT}/bin/g++)
 endif()
 
+if ("$ENV{PARQUET_USE_CCACHE}")
+  set(CMAKE_C_COMPILER_ARG1 ${CMAKE_C_COMPILER})
+  set(CMAKE_CXX_COMPILER_ARG1 ${CMAKE_CXX_COMPILER})
+  set(CMAKE_C_COMPILER ccache)
+  set(CMAKE_CXX_COMPILER ccache)
+endif()
+
 # generate CTest input files
 enable_testing()
 

http://git-wip-us.apache.org/repos/asf/parquet-cpp/blob/f3dbd5a4/src/parquet/schema/schema-converter-test.cc
----------------------------------------------------------------------
diff --git a/src/parquet/schema/schema-converter-test.cc b/src/parquet/schema/schema-converter-test.cc
index a5e1df7..f2dadf2 100644
--- a/src/parquet/schema/schema-converter-test.cc
+++ b/src/parquet/schema/schema-converter-test.cc
@@ -125,7 +125,7 @@ TEST_F(TestSchemaConverter, NotEnoughChildren) {
   SchemaElement elt;
   std::vector<SchemaElement> elements;
   elements.push_back(NewGroup(name_, FieldRepetitionType::REPEATED, 2));
-  ASSERT_THROW(Convert(&elements[0], 2), ParquetException);
+  ASSERT_THROW(Convert(&elements[0], 1), ParquetException);
 }
 
 // ----------------------------------------------------------------------


Mime
View raw message