changeset 1207:7121a40671ff

HashedFile: Forget to call the file hashing so only the file lengths were compared. flys-backend/trunk@2316 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Mon, 11 Jul 2011 10:02:13 +0000
parents c7370734b872
children 2b57edd94735
files flys-backend/ChangeLog flys-backend/src/main/java/de/intevation/flys/utils/FileTools.java
diffstat 2 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/ChangeLog	Mon Jul 11 09:31:52 2011 +0000
+++ b/flys-backend/ChangeLog	Mon Jul 11 10:02:13 2011 +0000
@@ -1,4 +1,10 @@
-2011-07-08	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+2011-07-11	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+
+	* src/main/java/de/intevation/flys/utils/FileTools.java: Argh!
+	  Forget to call the file hashing so only the file lengths were
+	  compared.
+
+2011-07-11	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
 
 	* src/main/java/de/intevation/flys/utils/FileTools.java:
 	  Added a class HashedFile to compare files by there length
--- a/flys-backend/src/main/java/de/intevation/flys/utils/FileTools.java	Mon Jul 11 09:31:52 2011 +0000
+++ b/flys-backend/src/main/java/de/intevation/flys/utils/FileTools.java	Mon Jul 11 10:02:13 2011 +0000
@@ -148,7 +148,7 @@
         public int compareTo(HashedFile other) {
             if (length < other.length) return -1;
             if (length > other.length) return +1;
-            return 0;
+            return compare(getHash(), other.getHash());
         }
 
         private static int compare(byte [] a, byte [] b) {

http://dive4elements.wald.intevation.org