From 8a498ef75e95c44161f787bb5d46ef75e4f96d96 Mon Sep 17 00:00:00 2001 From: Guilherme Maciel Ferreira Date: Mon, 6 Feb 2012 00:04:35 -0200 Subject: [PATCH] Fix: not all letter in the protocol_string_map key were uppercase, which caused the protocol_uppercase_string to do not index properly. --- src/host/pingprotocol.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/host/pingprotocol.cpp b/src/host/pingprotocol.cpp index e7078ea..0241895 100644 --- a/src/host/pingprotocol.cpp +++ b/src/host/pingprotocol.cpp @@ -41,9 +41,9 @@ PingProtocol get_ping_protocol_from_string( const string & protocol_string ) // TODO move to an init method protocol_string_map[ "ICMP" ] = PingProtocol_ICMP; - protocol_string_map[ "ICMPv6" ] = PingProtocol_ICMPv6; + protocol_string_map[ "ICMPV6" ] = PingProtocol_ICMPv6; protocol_string_map[ "TCP" ] = PingProtocol_TCP; - protocol_string_map[ "TCP_IPv6" ] = PingProtocol_TCP_IPv6; + protocol_string_map[ "TCP_IPV6" ] = PingProtocol_TCP_IPv6; PingProtocol protocol = protocol_string_map[ protocol_uppercase_string ]; -- 1.7.1