replaced old logger

This commit is contained in:
Erik Frojdh
2020-03-11 12:40:12 +01:00
parent 4aeb8bf62e
commit 0de0d82a1a
79 changed files with 3635 additions and 3814 deletions

View File

@ -107,7 +107,7 @@ int DataSocket::setTimeOut(int t_seconds) {
// Receive timeout indefinet
if (::setsockopt(getSocketId(), SOL_SOCKET, SO_RCVTIMEO, &t,
sizeof(struct timeval)) < 0) {
FILE_LOG(logERROR) << "setsockopt SO_RCVTIMEO " << 0;
LOG(logERROR) << "setsockopt SO_RCVTIMEO " << 0;
}
t.tv_sec = t_seconds;
@ -115,7 +115,7 @@ int DataSocket::setTimeOut(int t_seconds) {
// Sending timeout in seconds
if (::setsockopt(getSocketId(), SOL_SOCKET, SO_SNDTIMEO, &t,
sizeof(struct timeval)) < 0) {
FILE_LOG(logERROR) << "setsockopt SO_SNDTIMEO " << t_seconds;
LOG(logERROR) << "setsockopt SO_SNDTIMEO " << t_seconds;
}
return 0;
}

View File

@ -12,7 +12,7 @@ int ServerInterface::sendResult(int ret, void *retval, int retvalSize,
if (mess != nullptr) {
write(mess, MAX_STR_LENGTH);
} else {
FILE_LOG(logERROR) << "No error message provided for this "
LOG(logERROR) << "No error message provided for this "
"failure. Will mess up TCP\n";
}
} else {

View File

@ -46,7 +46,7 @@ int readDataFile(std::string fname, short int *data, int nch) {
iline=readDataFile(infile, data, nch, 0);
infile.close();
} else {
FILE_LOG(logERROR) << "Could not read file " << fname;
LOG(logERROR) << "Could not read file " << fname;
return -1;
}
return iline;
@ -73,7 +73,7 @@ int writeDataFile(std::string fname,int nch, short int *data) {
outfile.close();
return slsDetectorDefs::OK;
} else {
FILE_LOG(logERROR) << "Could not open file " << fname << "for writing";
LOG(logERROR) << "Could not open file " << fname << "for writing";
return slsDetectorDefs::FAIL;
}
}

View File

@ -14,7 +14,7 @@
#include <sys/prctl.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <unistd.h>
#include "network_utils.h"
namespace sls {