Boost logo

Boost Users :

Subject: Re: [Boost-users] SIGSEGV when removing Ethernet/Serial Port cables
From: Igor R (boost.lists_at_[hidden])
Date: 2013-10-30 16:25:35


> Have a boost enable application which communicated over
> USB serial ports and UDP
>
> If the cables are removed, the library fires off SIGSEGV signals.
>
> I am trying to catch exceptions but neither
> } catch (boost::system::system_error &e) {
> } catch (std::exception &e) {
> seems to work, and a SIGSEGV signal is sent when the
>
> port->get_io_service().reset();
>
> statement is executed.

If "port" is a raw pointer, check that it points to a valid object.
Anyway, segsegv is not translated to c++ exception (although one can
do that like this:
http://stackoverflow.com/questions/16777362/need-explanation-of-the-usage-of-assembler-and-linux-signal-processing).


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net