From 7d3e97b4a2f88265800d86d8f52352ae2996470c Mon Sep 17 00:00:00 2001 From: ebensza Date: Thu, 5 May 2016 13:07:13 +0200 Subject: [PATCH] hostid fix on solaris v2 Signed-off-by: ebensza --- core/Runtime.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/core/Runtime.cc b/core/Runtime.cc index cf54eb6..44c4ce1 100644 --- a/core/Runtime.cc +++ b/core/Runtime.cc @@ -303,13 +303,11 @@ CHARSTRING TTCN_Runtime::get_host_address(const CHARSTRING& type) } } if (type == "Ipv6") { - const IPv6Address * ipv6 = NULL; #if defined(LINUX) || defined(CYGWIN17) - ipv6 = dynamic_cast(address); + const IPv6Address * ipv6 = dynamic_cast(address); + if (ipv6 == NULL) #endif // LINUX || CYGWIN17 - if (ipv6 == NULL) { return CHARSTRING(""); - } } // Return the string representation of the address return CHARSTRING(address->get_addr_str()); -- 2.34.1