bool DomoticzTCP::StopHardwareTCP() { if (isConnected()) { try { disconnectTCP(); } catch(...) { //Don't throw from a Stop command } } else { try { if (m_thread) { m_stoprequested = true; m_thread->join(); } } catch (...) { //Don't throw from a Stop command } } m_bIsStarted=false; return true; }
int InetGSM::closemail() { char end_c[2]; end_c[0]=0x1a; end_c[1]='\0'; gsm.SimpleWrite("\n.\n"); gsm.SimpleWrite(end_c); disconnectTCP(); return 1; }