Discussion:
Program terminated with signal SIGFPE, Arithmetic exception
(too old to reply)
李绍开
2015-12-24 06:57:25 UTC
Permalink
Hello:

I use a timer, but when io_service done, sometimes(only few), a weired
errorr occurred:

Program terminated with signal SIGFPE, Arithmetic exception.
#0 0x0000000000442dab in asio::detail::epoll_reactor::run
(this=0x3c7600003c8a8000, block=false, ops=...)
at jni/asio-1.10.6/include/asio/detail/impl/epoll_reactor.ipp:394
394 bool check_timers = (timer_fd_ == -1);
(gdb) bt
#0 0x0000000000442dab in asio::detail::epoll_reactor::run
(this=0x3c7600003c8a8000, block=false, ops=...)
at jni/asio-1.10.6/include/asio/detail/impl/epoll_reactor.ipp:394
#1 0x000000000043b488 in
asio::detail::service_base<asio::detail::task_io_service>::~service_base
(this=0x36, __in_chrg=<optimized out>)
at jni/asio-1.10.6/include/asio/io_service.hpp:744
#2 0x000000000043bb93 in std::operator+<char, std::char_traits<char>,
std::allocator<char> >(std::basic_string<char, std::char_traits<char>,
std::allocator<char> >&&, std::basic_string<char, std::char_traits<char>,
std::allocator<char> >&&) (
__lhs=<unknown type in
/home/lishaokai/VoiceDemo/app/src/main/build64_debug/jni/violet/test_client,
CU 0x0, DIE 0x26beb>,
__rhs=<unknown type in
/home/lishaokai/VoiceDemo/app/src/main/build64_debug/jni/violet/test_client,
CU 0x0, DIE 0x26beb>)
at /usr/include/c++/4.8/bits/basic_string.h:2442
#3 0x00000000004444d8 in asio::detail::socket_ops::close (s=0,
state=@0x36: <error reading variable>, destruction=true, ec=...)
at jni/asio-1.10.6/include/asio/detail/impl/socket_ops.ipp:322
#4 0x00000000004429ae in asio::detail::epoll_reactor::start_op
(this=0x780000003e8, op_type=0, descriptor=0, descriptor_data=@0x15649f0:
0x157d1b0,
op=0x36, is_continuation=false, allow_speculative=176) at
jni/asio-1.10.6/include/asio/detail/impl/epoll_reactor.ipp:244
#5 0x0000000000442a34 in asio::detail::epoll_reactor::start_op (this=0x0,
op_type=0, descriptor=22432240,
descriptor_data=@0x7f1df80008c0: 0xc55a5e52a556e018, op=0x1564a30,
is_continuation=false, allow_speculative=104)
at jni/asio-1.10.6/include/asio/detail/impl/epoll_reactor.ipp:252
#6 0x000000000044b46d in
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<void*,
asio::detail::socket_ops::noop_deleter> (this=0x15649f0,
__p=0x0, __d=...) at /usr/include/c++/4.8/bits/shared_ptr_base.h:463
#7 0x000000000044b2f3 in
asio::detail::epoll_reactor::descriptor_state::~descriptor_state
(this=0x156b6f0, __in_chrg=<optimized out>)
at jni/asio-1.10.6/include/asio/detail/epoll_reactor.hpp:48
#8 0x000000000044b0db in
std::thread::_M_make_routine<std::_Bind_simple<std::_Mem_fn<void
(Controller::*)()> (Controller*)> >(std::_Bind_simple<std::_Mem_fn<void
(Controller::*)()> (Controller*)>&&) (this=0x7f1dfca1ce90,
__f=<unknown type in
/home/lishaokai/VoiceDemo/app/src/main/build64_debug/jni/violet/test_client,
CU 0x2aa0b, DIE 0x67951>)
at /usr/include/c++/4.8/thread:190



bool check_timers = (timer_fd_ == -1);
how is that could be a arithmetic error?


Thank you!
--
*狭路盞逢勇者胜*
Loading...