Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ g++ -ggdb bug.cpp `pkg-config --cflags --libs opencv`
- $ gdb a.out
- GNU gdb (Ubuntu 7.7-0ubuntu3.1) 7.7
- Copyright (C) 2014 Free Software Foundation, Inc.
- License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
- This is free software: you are free to change and redistribute it.
- There is NO WARRANTY, to the extent permitted by law. Type "show copying"
- and "show warranty" for details.
- This GDB was configured as "x86_64-linux-gnu".
- Type "show configuration" for configuration details.
- For bug reporting instructions, please see:
- <http://www.gnu.org/software/gdb/bugs/>.
- Find the GDB manual and other documentation resources online at:
- <http://www.gnu.org/software/gdb/documentation/>.
- For help, type "help".
- Type "apropos word" to search for commands related to "word"...
- Reading symbols from a.out...done.
- (gdb) run
- Starting program: a.out
- [Thread debugging using libthread_db enabled]
- Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
- Program received signal SIGSEGV, Segmentation fault.
- 0x00000000004d5b28 in cv::arithm_op(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, cv::_InputArray const&, int, void (**)(unsigned char const*, unsigned long, unsigned char const*, unsigned long, unsigned char*, unsigned long, cv::Size_<int>, void*), bool, void*) ()
- (gdb) bt
- #0 0x00000000004d5b28 in cv::arithm_op(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, cv::_InputArray const&, int, void (**)(unsigned char const*, unsigned long, unsigned char const*, unsigned long, unsigned char*, unsigned long, cv::Size_<int>, void*), bool, void*) ()
- #1 0x00000000004d8650 in cv::add(cv::_InputArray const&, cv::_InputArray const&, cv::_OutputArray const&, cv::_InputArray const&, int) ()
- #2 0x000000000040332c in cv::operator+= (a=..., s=...)
- at /home/tmp/opencv/install/include/opencv2/core/mat.hpp:1442
- #3 0x0000000000403782 in Bug::Bug (this=0x812042 <b>) at bug.cpp:6
- #4 0x000000000040338e in __static_initialization_and_destruction_0 (__initialize_p=1,
- __priority=65535) at bug.cpp:9
- #5 0x00000000004033a3 in _GLOBAL__sub_I_main () at bug.cpp:10
- #6 0x00000000005b5f0d in __libc_csu_init ()
- #7 0x00007ffff6defe55 in __libc_start_main (main=0x403337 <main(int, char**)>, argc=1,
- argv=0x7fffffffded8, init=0x5b5ec0 <__libc_csu_init>, fini=<optimized out>,
- rtld_fini=<optimized out>, stack_end=0x7fffffffdec8) at libc-start.c:246
- #8 0x00000000004031f7 in _start ()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement