flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cd...@apache.org
Subject [1/2] git commit: [flex-utilities] [refs/heads/develop] - - Fixed a ArrayIndexOutOfBounds problem in the SystemIdHelper
Date Mon, 20 Jul 2015 09:43:55 GMT
Repository: flex-utilities
Updated Branches:
  refs/heads/develop c282cd5dd -> 57a412750


- Fixed a ArrayIndexOutOfBounds problem in the SystemIdHelper


Project: http://git-wip-us.apache.org/repos/asf/flex-utilities/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-utilities/commit/a4a9c881
Tree: http://git-wip-us.apache.org/repos/asf/flex-utilities/tree/a4a9c881
Diff: http://git-wip-us.apache.org/repos/asf/flex-utilities/diff/a4a9c881

Branch: refs/heads/develop
Commit: a4a9c8813506fb386d850122c8f72aa95124d705
Parents: c282cd5
Author: Christofer Dutz <christofer.dutz@codecentric.de>
Authored: Mon Jul 20 11:42:27 2015 +0200
Committer: Christofer Dutz <christofer.dutz@codecentric.de>
Committed: Mon Jul 20 11:42:27 2015 +0200

----------------------------------------------------------------------
 .../utilities/converter/retrievers/download/SystemIdHelper.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-utilities/blob/a4a9c881/flex-maven-tools/mavenizer/retrievers/download/src/main/java/org/apache/flex/utilities/converter/retrievers/download/SystemIdHelper.java
----------------------------------------------------------------------
diff --git a/flex-maven-tools/mavenizer/retrievers/download/src/main/java/org/apache/flex/utilities/converter/retrievers/download/SystemIdHelper.java
b/flex-maven-tools/mavenizer/retrievers/download/src/main/java/org/apache/flex/utilities/converter/retrievers/download/SystemIdHelper.java
index 76d239e..837c27f 100644
--- a/flex-maven-tools/mavenizer/retrievers/download/src/main/java/org/apache/flex/utilities/converter/retrievers/download/SystemIdHelper.java
+++ b/flex-maven-tools/mavenizer/retrievers/download/src/main/java/org/apache/flex/utilities/converter/retrievers/download/SystemIdHelper.java
@@ -17,7 +17,7 @@ public abstract class SystemIdHelper {
             while (nis.hasMoreElements()) {
                 NetworkInterface ni = nis.nextElement();
                 byte[] mac = ni.getHardwareAddress();
-                if(mac != null) {
+                if((mac != null) && (mac.length >= 6)) {
                     macSum[0] = (byte) ((macSum[0] + mac[0]) % 256);
                     macSum[1] = (byte) ((macSum[1] + mac[1]) % 256);
                     macSum[2] = (byte) ((macSum[2] + mac[2]) % 256);


Mime
View raw message