diff --git a/CHANGES.txt b/CHANGES.txt index 65c4823c347..24da48af1d8 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -87,6 +87,9 @@ Trunk (unreleased changes) HADOOP-6613. Moves the RPC version check ahead of the AuthMethod check. (Kan Zhang via ddas) + HADOOP-6682. NetUtils:normalizeHostName does not process hostnames starting + with [a-f] correctly. (jghoman) + Release 0.21.0 - Unreleased INCOMPATIBLE CHANGES diff --git a/src/java/org/apache/hadoop/net/NetUtils.java b/src/java/org/apache/hadoop/net/NetUtils.java index e8590618726..bc81d5b79a8 100644 --- a/src/java/org/apache/hadoop/net/NetUtils.java +++ b/src/java/org/apache/hadoop/net/NetUtils.java @@ -398,7 +398,7 @@ public class NetUtils { * @return its IP address in the string format */ public static String normalizeHostName(String name) { - if (Character.digit(name.charAt(0), 16) != -1) { // it is an IP + if (Character.digit(name.charAt(0), 10) != -1) { // it is an IP return name; } else { try {