mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-23 18:17:59 +02:00
removed online flags, apiversion in shm, ret for ok and fail, bind socket help in exception message (#43)
* removed online flag, removed rxronline flag, added useReceier flag that is set only when rxr hostname is set, removed setonline, setreceiveronline flag, removed ret for ok or fail, using exceptions for this, changed cannot bind socket printout * fixed python
This commit is contained in:
@ -243,9 +243,9 @@ public:
|
||||
|
||||
|
||||
if(bind(sockfd.fd,(struct sockaddr *) &serverAddress,sizeof(serverAddress))<0){
|
||||
FILE_LOG(logERROR) << "Can not bind socket";
|
||||
FILE_LOG(logERROR) << "Can not bind socket. Please check if another process is running.";
|
||||
sockfd.fd =-1;
|
||||
throw SocketError("Can not bind socket");
|
||||
throw SocketError("Can not bind socket. Please check if another process is running.");
|
||||
}
|
||||
|
||||
|
||||
|
@ -262,17 +262,6 @@ format
|
||||
*/
|
||||
enum { GET_ACTION, PUT_ACTION, READOUT_ACTION, HELP_ACTION };
|
||||
|
||||
/** online flags enum \sa setOnline*/
|
||||
enum {
|
||||
GET_ONLINE_FLAG = -1, /**< returns wether the detector is in online or
|
||||
offline state */
|
||||
OFFLINE_FLAG = 0, /**< detector in offline state (i.e. no communication
|
||||
to the detector - using only local structure - no
|
||||
data acquisition possible!) */
|
||||
ONLINE_FLAG = 1 /**< detector in online state (i.e. communication to the
|
||||
detector updating the local structure) */
|
||||
};
|
||||
|
||||
/**
|
||||
flags to get (or set) the size of the detector
|
||||
*/
|
||||
|
@ -29,7 +29,7 @@ ServerSocket::ServerSocket(int port)
|
||||
if (bind(getSocketId(), (struct sockaddr *)&serverAddr,
|
||||
sizeof(serverAddr)) != 0) {
|
||||
close();
|
||||
throw sls::SocketError("Server ERROR: cannot bind socket");
|
||||
throw sls::SocketError("Server ERROR: cannot bind socket. Please check if another instance is running.");
|
||||
}
|
||||
if (listen(getSocketId(), DEFAULT_BACKLOG) != 0) {
|
||||
close();
|
||||
|
Reference in New Issue
Block a user