Giter Club home page Giter Club logo

Comments (3)

akretz avatar akretz commented on June 1, 2024 2

The buffer

AutoBuffer<Point2f> _result(n*2 + m*2 + 1);

overflows when it gets written by intersectConvexConvex_. I don't understand the logic well enough to say what the correct fix is.

from opencv.

asmorkalov avatar asmorkalov commented on June 1, 2024
Thread 1 "python3" received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
51      ../sysdeps/unix/sysv/linux/raise.c: Нет такого файла или каталога.
(gdb) bt
#0  0x00007ffff7a20e87 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007ffff7a227f1 in __GI_abort () at abort.c:79
#2  0x00007ffff7a6b837 in __libc_message (action=action@entry=do_abort, fmt=fmt@entry=0x7ffff7b98869 "*** %s ***: %s terminated\n") at ../sysdeps/posix/libc_fatal.c:181
#3  0x00007ffff7b16b31 in __GI___fortify_fail_abort (need_backtrace=need_backtrace@entry=false, msg=msg@entry=0x7ffff7b98847 "stack smashing detected") at fortify_fail.c:33
#4  0x00007ffff7b16af2 in __stack_chk_fail () at stack_chk_fail.c:29
#5  0x00007fffefd7bf11 in cv::intersectConvexConvex(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, bool) (_p1=..., _p2=..., _p12=..., handleNested=true) at /home/alexander/Projects/OpenCV/opencv-master/modules/imgproc/src/geometry.cpp:594
#6  0x00007ffff60cd8cf in pyopencv_cv_intersectConvexConvex(PyObject*, PyObject*, PyObject*) (py_args=0x7fffaa99ba20, kw=0x0) at /home/alexander/Projects/OpenCV/opencv-build/modules/python_bindings_generator/pyopencv_generated_funcs.h:16832
#7  0x000000000050a335 in  ()
#8  0x000000000050bcb4 in _PyEval_EvalFrameDefault ()
#9  0x0000000000507a64 in  ()
#10 0x000000000050ab13 in PyEval_EvalCode ()
#11 0x0000000000634ec2 in  ()
#12 0x0000000000634f77 in PyRun_FileExFlags ()
#13 0x000000000063872f in PyRun_SimpleFileExFlags ()
#14 0x00000000006392d1 in Py_Main ()
#15 0x00000000004b0db0 in main ()

from opencv.

asmorkalov avatar asmorkalov commented on June 1, 2024
alexander@paradox:~/tmp/opencv-python-repro$ python3 ./repro.py 
InputArray: empty()=false kind=0x00010000 flags=0x01010000 total(-1)=33 dims(-1)=2 size(-1)=1x33 type(-1)=CV_32FC2
InputArray: empty()=false kind=0x00010000 flags=0x01010000 total(-1)=33 dims(-1)=2 size(-1)=1x33 type(-1)=CV_32FC2
cv::intersectConvexConvex call
==21072==AddressSanitizer CHECK failed: ../../../../src/libsanitizer/asan/asan_interceptors.cc:384 "((__interception::real___cxa_throw)) != (0)" (0x0, 0x0)
    #0 0x7f12e7332bf2  (/usr/lib/gcc/x86_64-linux-gnu/7/libasan.so+0xe9bf2)
    #1 0x7f12e7351575 in __sanitizer::CheckFailed(char const*, int, char const*, unsigned long long, unsigned long long) (/usr/lib/gcc/x86_64-linux-gnu/7/libasan.so+0x108575)
    #2 0x7f12e728126c in __interceptor___cxa_throw (/usr/lib/gcc/x86_64-linux-gnu/7/libasan.so+0x3826c)
    #3 0x7f12d659f087 in ipp::iwiMirror(ipp::IwiImage const&, ipp::IwiImage&, IppiAxis, ipp::IwiMirrorParams const&, ipp::IwiTile const&) (/home/alexander/Projects/OpenCV/opencv-build/lib/libopencv_core.so.409+0x735087)
    #4 0x7f12d65aaa06 in cv::ipp_flip(cv::Mat&, cv::Mat&, int) (/home/alexander/Projects/OpenCV/opencv-build/lib/libopencv_core.so.409+0x740a06)
    #5 0x7f12d65ab450 in cv::flip(cv::_InputArray const&, cv::_OutputArray const&, int) (/home/alexander/Projects/OpenCV/opencv-build/lib/libopencv_core.so.409+0x741450)
    #6 0x7f12d823ad7b in cv::intersectConvexConvex(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, bool) (/home/alexander/Projects/OpenCV/opencv-build/lib/libopencv_imgproc.so.409+0x865d7b)
    #7 0x7f12e22242e3 in pyopencv_cv_intersectConvexConvex(_object*, _object*, _object*) (/home/alexander/Projects/OpenCV/opencv-build/lib/python3/cv2.cpython-36m-x86_64-linux-gnu.so+0x7b22e3)
    #8 0x50a334  (/usr/bin/python3.6+0x50a334)
    #9 0x50ca95 in _PyEval_EvalFrameDefault (/usr/bin/python3.6+0x50ca95)
    #10 0x507a63  (/usr/bin/python3.6+0x507a63)
    #11 0x50ab12 in PyEval_EvalCode (/usr/bin/python3.6+0x50ab12)
    #12 0x634ec1  (/usr/bin/python3.6+0x634ec1)
    #13 0x634f76 in PyRun_FileExFlags (/usr/bin/python3.6+0x634f76)
    #14 0x63872e in PyRun_SimpleFileExFlags (/usr/bin/python3.6+0x63872e)
    #15 0x6392d0 in Py_Main (/usr/bin/python3.6+0x6392d0)
    #16 0x4b0daf in main (/usr/bin/python3.6+0x4b0daf)
    #17 0x7f12e6e79c86 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21c86)
    #18 0x5b23a9 in _start (/usr/bin/python3.6+0x5b23a9)

from opencv.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.