From ce4126701e0999909121623e4d9417523b5a615b Mon Sep 17 00:00:00 2001 From: champtar Date: Wed, 20 Apr 2016 21:54:04 +0200 Subject: [PATCH] NetworkUtils: fix IndexOutOfBoundsException (#66) http://findbugs.sourceforge.net/bugDescriptions.html#RANGE_ARRAY_LENGTH Signed-off-by: Etienne CHAMPETIER --- src/main/java/org/ice4j/ice/NetworkUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/ice4j/ice/NetworkUtils.java b/src/main/java/org/ice4j/ice/NetworkUtils.java index 48aa738..b055755 100644 --- a/src/main/java/org/ice4j/ice/NetworkUtils.java +++ b/src/main/java/org/ice4j/ice/NetworkUtils.java @@ -530,7 +530,7 @@ public class NetworkUtils if (isMappedIPv4Addr(addr)) { byte[] newAddr = new byte[IN4_ADDR_SIZE]; - System.arraycopy(addr, 12, newAddr, 0, IN6_ADDR_SIZE); + System.arraycopy(addr, 12, newAddr, 0, IN4_ADDR_SIZE); return newAddr; }