$OpenBSD: patch-files_ml,v 1.2 2005/05/30 19:27:45 sturm Exp $
Post-release developer patch.
o Fix the problem with comparison of files using diff
  when the files are on two different hosts.
  See http://lists.seas.upenn.edu/pipermail/unison-hackers/2005-May/000067.html
--- files.ml.orig	Mon Sep  6 15:15:46 2004
+++ files.ml	Sun May 22 16:13:36 2005
@@ -469,8 +469,8 @@ let rec diff root1 path1 ui1 root2 path2
            Lwt_unix.run
              (Update.translatePath root2 path2 >>= (fun path2 ->
               Copy.file root2 path2 root1 workingDir tmppath realPath
-                `Copy (Props.setLength Props.fileSafe (Props.length desc1))
-                 fp1 ress1 id));
+                `Copy (Props.setLength Props.fileSafe (Props.length desc2))
+                 fp2 ress2 id));
            displayDiff
 	     (Fspath.concat workingDir realPath)
              (Fspath.concat workingDir tmppath);
@@ -487,8 +487,8 @@ let rec diff root1 path1 ui1 root2 path2
              (Update.translatePath root1 path1 >>= (fun path1 ->
               (* Note that we don't need the ressource fork *)
               Copy.file root1 path1 root2 workingDir tmppath realPath
-                `Copy (Props.setLength Props.fileSafe (Props.length desc2))
-                 fp2 ress2 id));
+                `Copy (Props.setLength Props.fileSafe (Props.length desc1))
+                 fp1 ress1 id));
            displayDiff
              (Fspath.concat workingDir tmppath)
 	     (Fspath.concat workingDir realPath);
