From fa61f094db96b0a3f1569cdc71052a319c73524c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Teppo=20J=C3=A4rvelin?= Date: Tue, 20 Mar 2018 16:24:43 +0200 Subject: [PATCH] Fixed coverity warning for class CellularUtil. --- features/cellular/framework/common/CellularUtil.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/features/cellular/framework/common/CellularUtil.cpp b/features/cellular/framework/common/CellularUtil.cpp index 406563951a..97ba9d7db9 100644 --- a/features/cellular/framework/common/CellularUtil.cpp +++ b/features/cellular/framework/common/CellularUtil.cpp @@ -168,7 +168,7 @@ void separate_ip_addresses(char* orig, char* ip, size_t ip_size, char* ip2, size if (ip2 && (ip2_size > strlen(temp))) { memcpy(ip2, temp, strlen(temp)); ip2[strlen(temp)] = '\0'; - } else { + } else if (ip2) { ip2[0] = '\0'; } } else {