strukturag / libheif

libheif is an HEIF and AVIF file format decoder and encoder.
Other
1.76k stars 302 forks source link

Segmentation fault when create a thumbnail from heic image #957

Closed zsuhoo closed 1 year ago

zsuhoo commented 1 year ago

@farindk Hi! Sometimes a segmentation fault occurs.

libheif-1.16.2 libvips-8.14.4 vips_thumbnail_buffer vips_image_write_to_buffer

Ubuntu 22.04

heic image is: IMG_0512.HEIC.zip

`Program terminated with signal 11, Segmentation fault.

0 0x00007f3969ea759a in void std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::_M_realloc_insert<ColorConversionOperation*>(__gnu_cxx::__normal_iterator<ColorConversionOperation*, std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> > >, ColorConversionOperation&&) () from /usr/local/lib64/libheif.so.1

warning: File "/usr/local/lib64/libstdc++.so.6.0.31-gdb.py" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load:/usr/bin/mono-gdb.py:/usr/lib/golang/src/runtime/runtime-gdb.py". Missing separate debuginfos, use: debuginfo-install OpenEXR-libs-1.7.1-8.el7.x86_64 bzip2-libs-1.0.6-13.el7.x86_64 cairo-1.15.12-4.el7.x86_64 cfitsio-3.370-10.el7.x86_64 expat-2.1.0-15.el7_9.x86_64 fontconfig-2.13.0-4.3.el7.x86_64 freetype-2.8-14.el7_9.1.x86_64 fribidi-1.0.2-1.el7_7.1.x86_64 gdk-pixbuf2-2.36.12-3.el7.x86_64 graphite2-1.3.10-1.el7_3.x86_64 harfbuzz-1.7.5-2.el7.x86_64 hdf5-1.8.12-13.el7.x86_64 ilmbase-1.0.3-7.el7.x86_64 jbigkit-libs-2.0-11.el7.x86_64 lcms2-2.6-3.el7.x86_64 libICE-1.0.9-9.el7.x86_64 libSM-1.2.2-2.el7.x86_64 libX11-1.6.7-4.el7_9.x86_64 libXau-1.0.8-2.1.el7.x86_64 libXext-1.3.3-3.el7.x86_64 libXrender-0.9.10-1.el7.x86_64 libXt-1.1.5-3.el7.x86_64 libaec-1.0.4-1.el7.x86_64 libblkid-2.23.2-65.el7_9.1.x86_64 libcroco-0.6.12-6.el7_9.x86_64 libexif-0.6.22-2.el7_9.x86_64 libffi-3.0.13-19.el7.x86_64 libglvnd-1.0.1-0.8.git5baa1e5.el7.x86_64 libglvnd-egl-1.0.1-0.8.git5baa1e5.el7.x86_64 libglvnd-glx-1.0.1-0.8.git5baa1e5.el7.x86_64 libgsf-1.14.26-7.el7.x86_64 libjpeg-turbo-1.2.90-8.el7.x86_64 libmount-2.23.2-65.el7_9.1.x86_64 libpng-1.5.13-8.el7.x86_64 librsvg2-2.40.20-1.el7.x86_64 libselinux-2.5-15.el7.x86_64 libthai-0.1.14-9.el7.x86_64 libtiff-4.0.3-35.el7.x86_64 libuuid-2.23.2-65.el7_9.1.x86_64 libxcb-1.13-1.el7.x86_64 libxml2-2.9.1-6.el7_9.6.x86_64 matio-1.5.17-3.el7.x86_64 openjpeg-libs-1.5.1-18.el7.x86_64 openjpeg2-2.3.1-3.el7_7.x86_64 openslide-3.4.1-1.el7.x86_64 pango-1.42.4-4.el7_7.x86_64 pcre-8.32-17.el7.x86_64 pixman-0.34.0-1.el7.x86_64 poppler-0.26.5-43.el7.1.x86_64 poppler-glib-0.26.5-43.el7.1.x86_64 sqlite-3.7.17-8.el7_7.1.x86_64 xz-libs-5.2.2-2.el7_9.x86_64 zlib-1.2.7-19.el7_9.x86_64 (gdb) bt

0 0x00007f3969ea759a in void std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::_M_realloc_insert<ColorConversionOperation*>(__gnu_cxx::__normal_iterator<ColorConversionOperation*, std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> > >, ColorConversionOperation&&) () from /usr/local/lib64/libheif.so.1

1 0x00007f3969ea65fa in void std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::emplace_back<ColorConversionOperation>(ColorConversionOperation&&) () from /usr/local/lib64/libheif.so.1

2 0x00007f3969ea5918 in std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::push_back(ColorConversionOperation*&&) () from /usr/local/lib64/libheif.so.1

3 0x00007f3969ea3086 in ColorConversionPipeline::init_ops() () from /usr/local/lib64/libheif.so.1

4 0x00007f3969ea3a56 in ColorConversionPipeline::construct_pipeline(ColorState const&, ColorState const&, heif_color_conversion_options const&) () from /usr/local/lib64/libheif.so.1

5 0x00007f3969ea4cda in convert_colorspace(std::shared_ptr const&, heif_colorspace, heif_chroma, std::shared_ptr const&, int, heif_color_conversion_options const&) ()

from /usr/local/lib64/libheif.so.1

6 0x00007f3969e63d21 in HeifContext::decode_image_planar(unsigned int, std::shared_ptr&, heif_colorspace, heif_decoding_options const&, bool) const () from /usr/local/lib64/libheif.so.1

7 0x00007f3969e668c3 in HeifContext::decode_and_paste_tile_image(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const () from /usr/local/lib64/libheif.so.1

8 0x00007f3969e7fca7 in Error std::__invoke_impl<Error, Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>(std::__invoke_memfun_deref, Error (HeifContext::&&)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const&&, unsigned int&&, std::shared_ptr&&, int&&, int&&, heif_decoding_options&&) () from /usr/local/lib64/libheif.so.1

9 0x00007f3969e7fa78 in std::__invoke_result<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>::type std::__invoke<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>(Error (HeifContext::&&)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const&&, unsigned int&&, std::shared_ptr&&, int&&, int&&, heif_decoding_options&&) () from /usr/local/lib64/libheif.so.1

10 0x00007f3969e7f84d in Error std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >::_M_invoke<0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul>(std::_Index_tuple<0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul>) () from /usr/local/lib64/libheif.so.1

11 0x00007f3969e7f613 in std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >::operator()() () from /usr/local/lib64/libheif.so.1

12 0x00007f3969e7f276 in std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::operator()() const ()

from /usr/local/lib64/libheif.so.1

13 0x00007f3969e7f05c in std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter> std::invoke_impl<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&>(std::__invoke_other, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&) () from /usr/local/lib64/libheif.so.1

14 0x00007f3969e7ecc0 in std::enable_if<!std::is_void<std::unique_ptr<std::future_base::_Result_base, std::__future_base::_Result_base::_Deleter> >::value, std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> >::type std::invoke_r<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter>, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&>(std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&) () from /usr/local/lib64/libheif.so.1

15 0x00007f3969e7e904 in std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> (), std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error> >::_M_invoke(std::_Any_data const&) () from /usr/local/lib64/libheif.so.1

16 0x00007f3969e6f79b in std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>::operator()() const () from /usr/local/lib64/libheif.so.1

17 0x00007f3969e6e347 in std::future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool) ()

from /usr/local/lib64/libheif.so.1

18 0x00007f3969e755b3 in void std::invoke_impl<void, void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*, std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool>(std::invoke_memfun_deref, void (std::future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>&&, bool*&&) () from /usr/local/lib64/libheif.so.1

---Type to continue, or q to quit---

19 0x00007f3969e722fb in std::invoke_result<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*, std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool>::type std::invoke<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&) () from /usr/local/lib64/libheif.so.1

20 0x00007f3969e6f5d2 in void std::call_once<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(std::once_flag&, void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&)::{lambda()#1}::operator()() const () from /usr/local/lib64/libheif.so.1

21 0x00007f3969e7232f in _ZZNSt9once_flag18_Prepare_executionC4IZSt9call_onceIMNSt13__future_base13_State_baseV2EFvPSt8functionIFSt10unique_ptrINS3_12_Result_baseENS7_8_DeleterEEvEEPbEJPS4_SC_SD_EEvRS_OT_DpOT0_EUlvE_EERSI_ENKUlvE_clEv () from /usr/local/lib64/libheif.so.1

22 0x00007f3969e72340 in _ZZNSt9once_flag18_Prepare_executionC4IZSt9call_onceIMNSt13__future_base13_State_baseV2EFvPSt8functionIFSt10unique_ptrINS3_12_Result_baseENS7_8_DeleterEEvEEPbEJPS4_SC_SD_EEvRS_OT_DpOT0_EUlvE_EERSI_ENUlvE_4_FUNEv () from /usr/local/lib64/libheif.so.1

23 0x00007f39770ac953 in pthread_once () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_once.S:103

24 0x00007f3969e5d09d in __gthread_once(int, void ()()) () from /usr/local/lib64/libheif.so.1

25 0x00007f3969e6f644 in void std::call_once<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(std::once_flag&, void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&) () from /usr/local/lib64/libheif.so.1

26 0x00007f3969e6e120 in std::future_base::_State_baseV2::_M_set_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool) ()

from /usr/local/lib64/libheif.so.1

27 0x00007f3969e7df7d in std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::_M_run() () from /usr/local/lib64/libheif.so.1

28 0x00007f3969e80c37 in void std::invoke_impl<void, void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::*)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>(std::invoke_memfun_deref, void (std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::&&)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>*&&) ()

from /usr/local/lib64/libheif.so.1

29 0x00007f3969e80b96 in std::invoke_result<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::*)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>::type std::invoke<void (std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>(void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::&&)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>*&&) () from /usr/local/lib64/libheif.so.1

30 0x00007f3969e80a05 in void std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>> >::_M_invoke<0ul, 1ul>(std::_Index_tuple<0ul, 1ul>) () from /usr/local/lib64/libheif.so.1

31 0x00007f3969e80922 in std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::*)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<---Type to continue, or q to quit---

Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>*> >::operator()() () from /usr/local/lib64/libheif.so.1

32 0x00007f3969e7fed2 in std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>> > >::_M_run() () from /usr/local/lib64/libheif.so.1

33 0x00007f396d6d9fbf in execute_native_thread_routine () from /usr/local/lib64/../lib64/libstdc++.so.6

34 0x00007f39770a71a3 in start_thread (arg=0x7f3955c5b700) at pthread_create.c:309

35 0x00007f3976dd9fad in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111

`

silverbacknet commented 1 year ago

I wonder if this is related to the same problem that caused XnView to have crashes while scrubbing through lots of images at once in 1.16. Unfortunately they just knee-jerk swapped it back after a report, instead of looking into it or getting crash dumps, and I haven't been able to reproduce to track it down.

zsuhoo commented 1 year ago

Sometimes got signal 6, Aborted.

Program terminated with signal 6, Aborted.

0 0x00007f5f2de712e7 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56

56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. warning: File "/usr/local/lib64/libstdc++.so.6.0.31-gdb.py" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load:/usr/bin/mono-gdb.py:/usr/lib/golang/src/runtime/runtime-gdb.py". Missing separate debuginfos, use: debuginfo-install OpenEXR-libs-1.7.1-8.el7.x86_64 bzip2-libs-1.0.6-13.el7.x86_64 cairo-1.15.12-4.el7.x86_64 cfitsio-3.370-10.el7.x86_64 expat-2.1.0-15.el7_9.x86_64 fontconfig-2.13.0-4.3.el7.x86_64 freetype-2.8-14.el7_9.1.x86_64 fribidi-1.0.2-1.el7_7.1.x86_64 gdk-pixbuf2-2.36.12-3.el7.x86_64 graphite2-1.3.10-1.el7_3.x86_64 harfbuzz-1.7.5-2.el7.x86_64 hdf5-1.8.12-13.el7.x86_64 ilmbase-1.0.3-7.el7.x86_64 jbigkit-libs-2.0-11.el7.x86_64 lcms2-2.6-3.el7.x86_64 libICE-1.0.9-9.el7.x86_64 libSM-1.2.2-2.el7.x86_64 libX11-1.6.7-4.el7_9.x86_64 libXau-1.0.8-2.1.el7.x86_64 libXext-1.3.3-3.el7.x86_64 libXrender-0.9.10-1.el7.x86_64 libXt-1.1.5-3.el7.x86_64 libaec-1.0.4-1.el7.x86_64 libblkid-2.23.2-65.el7_9.1.x86_64 libcroco-0.6.12-6.el7_9.x86_64 libexif-0.6.22-2.el7_9.x86_64 libffi-3.0.13-19.el7.x86_64 libglvnd-1.0.1-0.8.git5baa1e5.el7.x86_64 libglvnd-egl-1.0.1-0.8.git5baa1e5.el7.x86_64 libglvnd-glx-1.0.1-0.8.git5baa1e5.el7.x86_64 libgsf-1.14.26-7.el7.x86_64 libjpeg-turbo-1.2.90-8.el7.x86_64 libmount-2.23.2-65.el7_9.1.x86_64 libpng-1.5.13-8.el7.x86_64 librsvg2-2.40.20-1.el7.x86_64 libselinux-2.5-15.el7.x86_64 libthai-0.1.14-9.el7.x86_64 libtiff-4.0.3-35.el7.x86_64 libuuid-2.23.2-65.el7_9.1.x86_64 libxcb-1.13-1.el7.x86_64 libxml2-2.9.1-6.el7_9.6.x86_64 matio-1.5.17-3.el7.x86_64 openjpeg-libs-1.5.1-18.el7.x86_64 openjpeg2-2.3.1-3.el7_7.x86_64 openslide-3.4.1-1.el7.x86_64 pango-1.42.4-4.el7_7.x86_64 pcre-8.32-17.el7.x86_64 pixman-0.34.0-1.el7.x86_64 poppler-0.26.5-43.el7.1.x86_64 poppler-glib-0.26.5-43.el7.1.x86_64 sqlite-3.7.17-8.el7_7.1.x86_64 xz-libs-5.2.2-2.el7_9.x86_64 zlib-1.2.7-19.el7_9.x86_64 (gdb) bt

0 0x00007f5f2de712e7 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56

1 0x00007f5f2de726c8 in __GI_abort () at abort.c:89

2 0x00007f5f2deaf414 in __libc_message (do_abort=do_abort@entry=2, fmt=fmt@entry=0x7f5f2dfa46a8 " Error in `%s': %s: 0x%s \n") at ../sysdeps/posix/libc_fatal.c:175

3 0x00007f5f2deb4c7e in malloc_printerr (action=3, str=0x7f5f2dfa4890 "double free or corruption (fasttop)", ptr=) at malloc.c:4895

4 0x00007f5f2deb5957 in _int_free (av=, p=0x7f5f10002d60, have_lock=0) at malloc.c:3751

5 0x00007f5f20ff114c in std::__new_allocator<ColorConversionOperation*>::deallocate(ColorConversionOperation**, unsigned long) () from /usr/local/lib64/libheif.so.1

6 0x00007f5f20fef482 in std::_Vector_base<ColorConversionOperation, std::allocator<ColorConversionOperation> >::_M_deallocate(ColorConversionOperation**, unsigned long) () from /usr/local/lib64/libheif.so.1

7 0x00007f5f20ff0717 in void std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::_M_realloc_insert<ColorConversionOperation*>(__gnu_cxx::__normal_iterator<ColorConversionOperation*, std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> > >, ColorConversionOperation&&) () from /usr/local/lib64/libheif.so.1

8 0x00007f5f20fef5fa in void std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::emplace_back<ColorConversionOperation>(ColorConversionOperation&&) () from /usr/local/lib64/libheif.so.1

9 0x00007f5f20fee918 in std::vector<ColorConversionOperation, std::allocator<ColorConversionOperation> >::push_back(ColorConversionOperation*&&) () from /usr/local/lib64/libheif.so.1

10 0x00007f5f20fec0c5 in ColorConversionPipeline::init_ops() () from /usr/local/lib64/libheif.so.1

11 0x00007f5f20feca56 in ColorConversionPipeline::construct_pipeline(ColorState const&, ColorState const&, heif_color_conversion_options const&) () from /usr/local/lib64/libheif.so.1

12 0x00007f5f20fedcda in convert_colorspace(std::shared_ptr const&, heif_colorspace, heif_chroma, std::shared_ptr const&, int, heif_color_conversion_options const&) ()

from /usr/local/lib64/libheif.so.1

13 0x00007f5f20facd21 in HeifContext::decode_image_planar(unsigned int, std::shared_ptr&, heif_colorspace, heif_decoding_options const&, bool) const () from /usr/local/lib64/libheif.so.1

14 0x00007f5f20faf8c3 in HeifContext::decode_and_paste_tile_image(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const () from /usr/local/lib64/libheif.so.1

15 0x00007f5f20fc8ca7 in Error std::__invoke_impl<Error, Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>(std::__invoke_memfun_deref, Error (HeifContext::&&)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const&&, unsigned int&&, std::shared_ptr&&, int&&, int&&, heif_decoding_options&&) () from /usr/local/lib64/libheif.so.1

16 0x00007f5f20fc8a78 in std::__invoke_result<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>::type std::__invoke<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options>(Error (HeifContext::&&)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const&&, unsigned int&&, std::shared_ptr&&, int&&, int&&, heif_decoding_options&&) () from /usr/local/lib64/libheif.so.1

17 0x00007f5f20fc884d in Error std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >::_M_invoke<0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul>(std::_Index_tuple<0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul>) () from /usr/local/lib64/libheif.so.1

18 0x00007f5f20fc8613 in std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >::operator()() () from /usr/local/lib64/libheif.so.1

19 0x00007f5f20fc8276 in std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::operator()() const ()

from /usr/local/lib64/libheif.so.1

20 0x00007f5f20fc805c in std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter> std::invoke_impl<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&>(std::__invoke_other, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&) () from /usr/local/lib64/libheif.so.1

21 0x00007f5f20fc7cc0 in std::enable_if<!std::is_void<std::unique_ptr<std::future_base::_Result_base, std::__future_base::_Result_base::_Deleter> >::value, std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> >::type std::invoke_r<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter>, std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&>(std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&) () from /usr/local/lib64/libheif.so.1

22 0x00007f5f20fc7904 in std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> (), std::future_base::_Task_setter<std::unique_ptr<std::future_base::_Result, std::future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error> >::_M_invoke(std::_Any_data const&) () from /usr/local/lib64/libheif.so.1

---Type to continue, or q to quit---

23 0x00007f5f20fb879b in std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>::operator()() const () from /usr/local/lib64/libheif.so.1

24 0x00007f5f20fb7347 in std::future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool) ()

from /usr/local/lib64/libheif.so.1

25 0x00007f5f20fbe5b3 in void std::invoke_impl<void, void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*, std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool>(std::invoke_memfun_deref, void (std::future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>&&, bool*&&) () from /usr/local/lib64/libheif.so.1

26 0x00007f5f20fbb2fb in std::invoke_result<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*, std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool>::type std::invoke<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&) () from /usr/local/lib64/libheif.so.1

27 0x00007f5f20fb85d2 in void std::call_once<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(std::once_flag&, void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&)::{lambda()#1}::operator()() const () from /usr/local/lib64/libheif.so.1

28 0x00007f5f20fbb32f in _ZZNSt9once_flag18_Prepare_executionC4IZSt9call_onceIMNSt13__future_base13_State_baseV2EFvPSt8functionIFSt10unique_ptrINS3_12_Result_baseENS7_8_DeleterEEvEEPbEJPS4_SC_SD_EEvRS_OT_DpOT0_EUlvE_EERSI_ENKUlvE_clEv () from /usr/local/lib64/libheif.so.1

29 0x00007f5f20fbb340 in _ZZNSt9once_flag18_Prepare_executionC4IZSt9call_onceIMNSt13__future_base13_State_baseV2EFvPSt8functionIFSt10unique_ptrINS3_12_Result_baseENS7_8_DeleterEEvEEPbEJPS4_SC_SD_EEvRS_OT_DpOT0_EUlvE_EERSI_ENUlvE_4_FUNEv () from /usr/local/lib64/libheif.so.1

30 0x00007f5f2e1f5953 in pthread_once () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_once.S:103

31 0x00007f5f20fa609d in __gthread_once(int, void ()()) () from /usr/local/lib64/libheif.so.1

32 0x00007f5f20fb8644 in void std::call_once<void (std::future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool>(std::once_flag&, void (std::__future_base::_State_baseV2::&&)(std::function<std::unique_ptr<std::future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool), std::future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>&&, bool&&) () from /usr/local/lib64/libheif.so.1

33 0x00007f5f20fb7120 in std::future_base::_State_baseV2::_M_set_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::future_base::_Result_base::_Deleter> ()>, bool) ()

from /usr/local/lib64/libheif.so.1

34 0x00007f5f20fc6f7d in std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::_M_run() () from /usr/local/lib64/libheif.so.1

35 0x00007f5f20fc9c37 in void std::invoke_impl<void, void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::*)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>(std::invoke_memfun_deref, void (std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::&&)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>*&&) ()

from /usr/local/lib64/libheif.so.1

36 0x00007f5f20fc9b96 in std::invoke_result<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::*)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>::type std::invoke<void (std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>>(void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::&&)(), std::future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::*)(unsigned int, std::shared_ptr const&, int, in---Type to continue, or q to quit---

t, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>&&) () from /usr/local/lib64/libheif.so.1

37 0x00007f5f20fc9a05 in void std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>> >::_M_invoke<0ul, 1ul>(std::_Index_tuple<0ul, 1ul>) () from /usr/local/lib64/libheif.so.1

38 0x00007f5f20fc9922 in std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>> >::operator()() () from /usr/local/lib64/libheif.so.1

39 0x00007f5f20fc8ed2 in std::thread::_State_impl<std::thread::_Invoker<std::tuple<void (std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>::)(), std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<Error (HeifContext::)(unsigned int, std::shared_ptr const&, int, int, heif_decoding_options const&) const, HeifContext const, unsigned int, std::shared_ptr, int, int, heif_decoding_options> >, Error>> > >::_M_run() () from /usr/local/lib64/libheif.so.1

40 0x00007f5f24822fbf in execute_native_thread_routine () from /usr/local/lib64/../lib64/libstdc++.so.6

41 0x00007f5f2e1f01a3 in start_thread (arg=0x7f5f1745e700) at pthread_create.c:309

42 0x00007f5f2df22fad in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111

farindk commented 1 year ago

Probably a duplicate of #950, fix proposed in PR #951.

zsuhoo commented 1 year ago

Thank you!