aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Log.cpp2
-rw-r--r--src/Log.h2
-rw-r--r--src/ParserConfigfile.cpp8
-rw-r--r--src/UdpSocket.h2
-rw-r--r--src/dabInputZmq.h3
-rw-r--r--src/dabOutput/dabOutput.h23
6 files changed, 20 insertions, 20 deletions
diff --git a/src/Log.cpp b/src/Log.cpp
index 30cc1f7..e428a0b 100644
--- a/src/Log.cpp
+++ b/src/Log.cpp
@@ -70,7 +70,7 @@ void Logger::logstr(log_level_t level, std::string message)
for (std::list<LogBackend*>::iterator it = backends.begin();
it != backends.end();
- it++) {
+ ++it) {
(*it)->log(level, message);
}
diff --git a/src/Log.h b/src/Log.h
index 5c8c4b3..4f911dc 100644
--- a/src/Log.h
+++ b/src/Log.h
@@ -135,7 +135,7 @@ class Logger {
/* Log the message to all backends */
void log(log_level_t level, const char* fmt, ...);
- void logstr(log_level_t level, const std::string message);
+ void logstr(log_level_t level, std::string message);
/* Return a LogLine for the given level
* so that you can write etiLog.level(info) << "stuff = " << 21 */
diff --git a/src/ParserConfigfile.cpp b/src/ParserConfigfile.cpp
index 14d9e6b..e513fa3 100644
--- a/src/ParserConfigfile.cpp
+++ b/src/ParserConfigfile.cpp
@@ -213,7 +213,7 @@ void parse_configfile(string configuration_file,
ptree pt_services = pt.get_child("services");
for (ptree::iterator it = pt_services.begin();
- it != pt_services.end(); it++) {
+ it != pt_services.end(); ++it) {
string serviceuid = it->first;
ptree pt_service = it->second;
dabService* service = new dabService();
@@ -264,7 +264,7 @@ void parse_configfile(string configuration_file,
map<string, dabSubchannel*> allsubchans;
ptree pt_subchans = pt.get_child("subchannels");
- for (ptree::iterator it = pt_subchans.begin(); it != pt_subchans.end(); it++) {
+ for (ptree::iterator it = pt_subchans.begin(); it != pt_subchans.end(); ++it) {
string subchanuid = it->first;
dabSubchannel* subchan = new dabSubchannel();
@@ -294,7 +294,7 @@ void parse_configfile(string configuration_file,
/******************** READ COMPONENT PARAMETERS ************/
map<string, dabComponent*> allcomponents;
ptree pt_components = pt.get_child("components");
- for (ptree::iterator it = pt_components.begin(); it != pt_components.end(); it++) {
+ for (ptree::iterator it = pt_components.begin(); it != pt_components.end(); ++it) {
string componentuid = it->first;
ptree pt_comp = it->second;
@@ -371,7 +371,7 @@ void parse_configfile(string configuration_file,
/******************** READ OUTPUT PARAMETERS ***************/
map<string, dabOutput*> alloutputs;
ptree pt_outputs = pt.get_child("outputs");
- for (ptree::iterator it = pt_outputs.begin(); it != pt_outputs.end(); it++) {
+ for (ptree::iterator it = pt_outputs.begin(); it != pt_outputs.end(); ++it) {
string outputuid = it->first;
string uri = pt_outputs.get<string>(outputuid);
diff --git a/src/UdpSocket.h b/src/UdpSocket.h
index a500606..d96e01e 100644
--- a/src/UdpSocket.h
+++ b/src/UdpSocket.h
@@ -115,7 +115,7 @@ class UdpPacket {
void setSize(unsigned newSize);
InetAddress &getAddress();
// Not implemented
- const UdpPacket &operator=(const UdpPacket&);
+ const UdpPacket& operator=(const UdpPacket&);
private:
char *dataBuf;
diff --git a/src/dabInputZmq.h b/src/dabInputZmq.h
index 3902963..b012cf6 100644
--- a/src/dabInputZmq.h
+++ b/src/dabInputZmq.h
@@ -65,7 +65,8 @@ class DabInputZmq : public DabInputBase {
DabInputZmq(const std::string name)
: m_name(name), m_zmq_context(1),
m_zmq_sock(m_zmq_context, ZMQ_SUB),
- m_prebuffering(INPUT_ZMQ_PREBUFFERING) {}
+ m_prebuffering(INPUT_ZMQ_PREBUFFERING),
+ m_bitrate(0) {}
virtual int open(const std::string inputUri);
virtual int readFrame(void* buffer, int size);
diff --git a/src/dabOutput/dabOutput.h b/src/dabOutput/dabOutput.h
index 5cb619f..bbf27e3 100644
--- a/src/dabOutput/dabOutput.h
+++ b/src/dabOutput/dabOutput.h
@@ -134,13 +134,16 @@ class DabOutputRaw : public DabOutput
#ifndef _WIN32
isCyclades_ = other.isCyclades_;
#endif
- buffer_ = other.buffer_;
+ buffer_ = new unsigned char[6144];
+ memcpy(buffer_, other.buffer_, 6144);
}
~DabOutputRaw() {
delete[] buffer_;
}
+ const DabOutputRaw operator=(const DabOutputRaw& other);
+
int Open(const char* name);
int Write(void* buffer, int size);
int Close();
@@ -164,11 +167,11 @@ class DabOutputUdp : public DabOutput
socket_ = new UdpSocket();
}
- DabOutputUdp(const DabOutputUdp& other)
- {
- packet_ = other.packet_;
- socket_ = other.socket_;
- }
+ // make sure we don't copy this output around
+ // the UdpPacket and UdpSocket do not support
+ // copying either
+ DabOutputUdp(const DabOutputUdp& other);
+ DabOutputUdp operator=(const DabOutputUdp& other);
~DabOutputUdp() {
delete socket_;
@@ -195,12 +198,8 @@ class DabOutputTcp : public DabOutput
client = NULL;
}
- DabOutputTcp(const DabOutputTcp& other)
- {
- server = other.server;
- client = other.client;
- thread_ = other.thread_;
- }
+ DabOutputTcp(const DabOutputTcp& other);
+ DabOutputTcp operator=(const DabOutputTcp& other);
~DabOutputTcp() {