From b74fd339e942f438e288f9e26cca404a5a430925 Mon Sep 17 00:00:00 2001 From: Lars Op den Kamp Date: Thu, 2 Feb 2012 11:09:43 +0100 Subject: [PATCH] cosmetics --- src/lib/adapter/USBCECAdapterCommunication.cpp | 4 +--- src/testclient/main.cpp | 6 +++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/lib/adapter/USBCECAdapterCommunication.cpp b/src/lib/adapter/USBCECAdapterCommunication.cpp index b439f74..12b8eac 100644 --- a/src/lib/adapter/USBCECAdapterCommunication.cpp +++ b/src/lib/adapter/USBCECAdapterCommunication.cpp @@ -605,9 +605,7 @@ void CUSBCECAdapterCommunication::SendMessageToAdapter(CCECAdapterMessage *msg) if (m_port->Write(msg->packet.data, msg->Size()) != (ssize_t) msg->Size()) { - CStdString strError; - strError.Format("error writing to serial port: %s", m_port->GetError().c_str()); - CLibCEC::AddLog(CEC_LOG_ERROR, strError); + CLibCEC::AddLog(CEC_LOG_ERROR, "error writing to serial port: %s", m_port->GetError().c_str()); msg->state = ADAPTER_MESSAGE_STATE_ERROR; } else diff --git a/src/testclient/main.cpp b/src/testclient/main.cpp index f6152e0..b324de2 100644 --- a/src/testclient/main.cpp +++ b/src/testclient/main.cpp @@ -190,16 +190,16 @@ void EnableCallbacks(ICECAdapter *adapter) void ListDevices(ICECAdapter *parser) { cec_adapter *devices = new cec_adapter[10]; - uint8_t iDevicesFound = parser->FindAdapters(devices, 10, NULL); + int8_t iDevicesFound = parser->FindAdapters(devices, 10, NULL); if (iDevicesFound <= 0) { PrintToStdOut("Found devices: NONE"); } else { - PrintToStdOut("Found devices: %d", iDevicesFound); + PrintToStdOut("Found devices: %d\n", iDevicesFound); for (unsigned int iDevicePtr = 0; iDevicePtr < iDevicesFound; iDevicePtr++) - PrintToStdOut("device: %d\npath: %s\ncom port: %s", iDevicePtr + 1, devices[iDevicePtr].path, devices[iDevicePtr].comm); + PrintToStdOut("device: %d\npath: %s\ncom port: %s\n", iDevicePtr + 1, devices[iDevicePtr].path, devices[iDevicePtr].comm); } } -- 2.34.1