From 264181153dcc512f19436e230bf700563bbda895 2012-07-31 16:49:03 From: HanzZ Date: 2012-07-31 16:49:03 Subject: [PATCH] Merge branch 'master' of github.com:hanzz/libtransport --- diff --git a/src/networkpluginserver.cpp b/src/networkpluginserver.cpp index 2f197b2b9fd113a5bc75d3c32fb17364f23084bc..bdf3831de076486165100cff24a3a7faf90b754f 100644 --- a/src/networkpluginserver.cpp +++ b/src/networkpluginserver.cpp @@ -952,6 +952,17 @@ void NetworkPluginServer::pingTimeout() { else { LOG4CXX_INFO(logger, "Disconnecting backend " << (*it) << " (ID=" << (*it)->id << "). PING response not received."); toRemove.push_back(*it); + +#ifndef WIN32 + // generate coredump for this backend to find out why it wasn't able to respond to PING + std::string pid = (*it)->id; + if (!pid.empty()) { + try { + kill(boost::lexical_cast(pid), SIGABRT); + } + catch (...) { } + } +#endif } if ((*it)->users.size() == 0) {