X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Flib%2FCECClient.cpp;h=ed3f47eecc23e04976bd3ed560184f3ea8155908;hb=4a69e83cb270fde99b0991e8c8443d09cc61b102;hp=cafcd700d0ab8c40a484477d22721b25da3da878;hpb=c01e7bea15b9d82fe8b616b022f82265d9b437a2;p=deb_libcec.git diff --git a/src/lib/CECClient.cpp b/src/lib/CECClient.cpp index cafcd70..ed3f47e 100644 --- a/src/lib/CECClient.cpp +++ b/src/lib/CECClient.cpp @@ -1076,7 +1076,7 @@ std::string CCECClient::GetConnectionInfo(void) { time_t buildTime = (time_t)m_configuration.iFirmwareBuildDate; strLog.AppendFormat(", firmware build date: %s", asctime(gmtime(&buildTime))); - strLog = strLog.Left((int)strLog.length() - 1); // strip \n added by asctime + strLog = strLog.substr(0, strLog.length() > 0 ? (size_t)(strLog.length() - 1) : 0); // strip \n added by asctime strLog.append(" +0000"); }