summaryrefslogtreecommitdiffstats
path: root/src/dabInputUdp.cpp
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2014-01-12 21:54:07 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2014-01-12 21:54:07 +0100
commitf1874c259259a039227517a9cd58d7017a1bef34 (patch)
treefb1cc85521a67d5efb05434fe78cb43a4098e03d /src/dabInputUdp.cpp
parente9c4e1762c3b7531ffe82dc26c67919ee38bfc3a (diff)
downloaddabmux-f1874c259259a039227517a9cd58d7017a1bef34.tar.gz
dabmux-f1874c259259a039227517a9cd58d7017a1bef34.tar.bz2
dabmux-f1874c259259a039227517a9cd58d7017a1bef34.zip
replace all occurrencies of TcpLog and old etiLog
Diffstat (limited to 'src/dabInputUdp.cpp')
-rw-r--r--src/dabInputUdp.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/dabInputUdp.cpp b/src/dabInputUdp.cpp
index b128584..ee3ab32 100644
--- a/src/dabInputUdp.cpp
+++ b/src/dabInputUdp.cpp
@@ -71,7 +71,7 @@ int dabInputUdpOpen(void* args, const char* inputName)
address = strdup(inputName);
ptr = strchr(address, ':');
if (ptr == NULL) {
- etiLog.print(TcpLog::ERR,
+ etiLog.log(error,
"\"%s\" is an invalid format for udp address: "
"should be [address]:port - > aborting\n", address);
returnCode = -1;
@@ -79,25 +79,25 @@ int dabInputUdpOpen(void* args, const char* inputName)
*(ptr++) = 0;
port = strtol(ptr, (char **)NULL, 10);
if ((port == LONG_MIN) || (port == LONG_MAX)) {
- etiLog.print(TcpLog::ERR,
+ etiLog.log(error,
"can't convert port number in udp address %s\n",
address);
returnCode = -1;
}
if (port == 0) {
- etiLog.print(TcpLog::ERR, "can't use port number 0 in udp address\n");
+ etiLog.log(error, "can't use port number 0 in udp address\n");
returnCode = -1;
}
dabInputUdpData* input = (dabInputUdpData*)args;
if (input->socket->create(port) == -1) {
- etiLog.print(TcpLog::ERR, "can't set port %i on Udp input (%s: %s)\n",
+ etiLog.log(error, "can't set port %i on Udp input (%s: %s)\n",
port, inetErrDesc, inetErrMsg);
returnCode = -1;
}
if (*address != 0) {
if (input->socket->joinGroup(address) == -1) {
- etiLog.print(TcpLog::ERR,
+ etiLog.log(error,
"can't join multicast group %s (%s: %s)\n",
address, inetErrDesc, inetErrMsg);
returnCode = -1;
@@ -105,13 +105,13 @@ int dabInputUdpOpen(void* args, const char* inputName)
}
if (input->socket->setBlocking(false) == -1) {
- etiLog.print(TcpLog::ERR, "can't set Udp input socket in blocking mode "
+ etiLog.log(error, "can't set Udp input socket in blocking mode "
"(%s: %s)\n", inetErrDesc, inetErrMsg);
returnCode = -1;
}
free(address);
- etiLog.print(TcpLog::DBG, "check return code of create\n");
+ etiLog.log(debug, "check return code of create\n");
return returnCode;;
}
@@ -154,14 +154,14 @@ int dabInputUdpRead(dabInputOperations* ops, void* args, void* buffer, int size)
input->stats.frameRecords[input->stats.frameCount].curSize = nbBytes;
if (++stats->frameCount == NB_RECORDS) {
- etiLog.print(TcpLog::INFO, "Data subchannel usage: (%i)",
+ etiLog.log(info, "Data subchannel usage: (%i)",
stats->id);
for (int i = 0; i < stats->frameCount; ++i) {
- etiLog.print(TcpLog::INFO, " %i/%i",
+ etiLog.log(info, " %i/%i",
stats->frameRecords[i].curSize,
stats->frameRecords[i].maxSize);
}
- etiLog.print(TcpLog::INFO, "\n");
+ etiLog.log(info, "\n");
stats->frameCount = 0;
}