Version in base suite: 1.67.0-13 Base version: boost1.67_1.67.0-13 Target version: boost1.67_1.67.0-13+deb10u1 Base file: /srv/ftp-master.debian.org/ftp/pool/main/b/boost1.67/boost1.67_1.67.0-13.dsc Target file: /srv/ftp-master.debian.org/policy/pool/main/b/boost1.67/boost1.67_1.67.0-13+deb10u1.dsc changelog | 8 +++++ patches/ed4776b59caec6dfbea548a96701a810653e6f24.patch | 25 +++++++++++++++++ patches/series | 1 3 files changed, 34 insertions(+) diff -Nru boost1.67-1.67.0/debian/changelog boost1.67-1.67.0/debian/changelog --- boost1.67-1.67.0/debian/changelog 2019-02-04 14:25:45.000000000 +0000 +++ boost1.67-1.67.0/debian/changelog 2020-01-26 19:20:04.000000000 +0000 @@ -1,3 +1,11 @@ +boost1.67 (1.67.0-13+deb10u1) buster; urgency=medium + + * Non-maintainer upload. + * Patch undefined behaviour leading to crashing libboost-numpy (closes: + #945987). + + -- Adrian Bunk Sun, 26 Jan 2020 21:20:04 +0200 + boost1.67 (1.67.0-13) unstable; urgency=medium * [c573257] Fix FTBFS in boost.compute with GCC-8. (Closes: #921247) diff -Nru boost1.67-1.67.0/debian/patches/ed4776b59caec6dfbea548a96701a810653e6f24.patch boost1.67-1.67.0/debian/patches/ed4776b59caec6dfbea548a96701a810653e6f24.patch --- boost1.67-1.67.0/debian/patches/ed4776b59caec6dfbea548a96701a810653e6f24.patch 1970-01-01 00:00:00.000000000 +0000 +++ boost1.67-1.67.0/debian/patches/ed4776b59caec6dfbea548a96701a810653e6f24.patch 2020-01-26 19:19:32.000000000 +0000 @@ -0,0 +1,25 @@ +From: Moritz Wanzenböck +Date: Wed Jul 11 11:57:46 2018 +0200 +Subject: Add missing return statement in numpy import + +This adds a missing return statement in the python3 specific +import logic of boost.python.numpy. + +For python3 wrap_import_array() needs to return a pointer value. +The import_array() macro only returns NULL in case of error. The +missing return statement is UB, so the compiler can assume it does +not happen. This means the compiler can assume the error branch +is always taken, so import_array must always fail. + +diff --git a/libs/python/src/numpy/numpy.cpp b/libs/python/src/numpy/numpy.cpp +index 8e259bc7..3ae2295e 100644 +--- a/libs/python/src/numpy/numpy.cpp ++++ b/libs/python/src/numpy/numpy.cpp +@@ -19,6 +19,7 @@ static void wrap_import_array() + static void * wrap_import_array() + { + import_array(); ++ return NULL; + } + #endif + diff -Nru boost1.67-1.67.0/debian/patches/series boost1.67-1.67.0/debian/patches/series --- boost1.67-1.67.0/debian/patches/series 2019-02-04 14:21:14.000000000 +0000 +++ boost1.67-1.67.0/debian/patches/series 2020-01-26 19:19:47.000000000 +0000 @@ -18,3 +18,4 @@ fix_linux_detection.patch 002-fix-powerpc-uClibc-build-issue.patch fix-boost-compute-gcc8-ftbfs.patch +ed4776b59caec6dfbea548a96701a810653e6f24.patch