merging with master

This commit is contained in:
Dhanya Maliakal
2015-08-21 14:47:07 +02:00
4 changed files with 63 additions and 35 deletions

View File

@ -65,7 +65,6 @@ slsReceiverTCPIPInterface::slsReceiverTCPIPInterface(int &success, UDPInterface*
strcpy(socket->lastClientIP,"none");
strcpy(socket->thisClientIP,"none1");
strcpy(mess,"dummy message");
function_table();
#ifdef VERBOSE
cout << "Function table assigned." << endl;
@ -148,8 +147,18 @@ void slsReceiverTCPIPInterface::stop(){
cout<<"Shutting down TCP Socket and TCP thread"<<endl;
cout << "Shutting down UDP Socket" << endl;
if(receiverBase){
receiverBase->shutDownUDPSockets();
cout << "Closing Files... " << endl;
receiverBase->closeFile();
}
killTCPServerThread = 1;
socket->ShutDownSocket();
socket->exitServer();
cout<<"Socket closed"<<endl;
void* status;
pthread_join(TCPServer_thread, &status);
@ -207,6 +216,7 @@ void slsReceiverTCPIPInterface::startTCPServer(){
receiverBase->closeFile();
}
socket->exitServer();
pthread_exit(NULL);
}