8076325
diff -ru desktop.orig/source/deployment/misc/dp_misc.cxx desktop/source/deployment/misc/dp_misc.cxx
8076325
--- desktop.orig/source/deployment/misc/dp_misc.cxx	2010-07-20 08:31:24.000000000 +0100
8076325
+++ desktop/source/deployment/misc/dp_misc.cxx	2010-07-20 09:12:23.000000000 +0100
8076325
@@ -143,6 +143,23 @@
8076325
     return pipe.is();
8076325
 }
8076325
 
8076325
+//get modification time
8076325
+static bool getModifyTimeTargetFile(const OUString &rFileURL, TimeValue &rTime)
8076325
+{
8076325
+    ::osl::DirectoryItem item;
8076325
+    if (::osl::DirectoryItem::get(rFileURL, item) != ::osl::File::E_None)
8076325
+        return false;
8076325
+
8076325
+    ::osl::FileStatus stat(FileStatusMask_ModifyTime|FileStatusMask_Type|FileStatusMask_LinkTargetURL);
8076325
+    if (item.getFileStatus(stat) != ::osl::File::E_None)
8076325
+        return false;
8076325
+
8076325
+    if( stat.getFileType() == ::osl::FileStatus::Link )
8076325
+        return getModifyTimeTargetFile(stat.getLinkTargetURL(), rTime);
8076325
+
8076325
+    rTime = stat.getModifyTime();
8076325
+    return true;
8076325
+}
8076325
 
8076325
 //Returns true if the Folder was more recently modified then
8076325
 //the lastsynchronized file. That is the repository needs to
8076325
@@ -181,15 +198,12 @@
8076325
     
8076325
     //compare the modification time of the extension folder and the last
8076325
     //modified file
8076325
-    ::osl::FileStatus statFolder(FileStatusMask_ModifyTime);
8076325
-    ::osl::FileStatus statFile(FileStatusMask_ModifyTime);
8076325
-    if (itemExtFolder.getFileStatus(statFolder) == ::osl::File::E_None)
8076325
+    TimeValue timeFolder;
8076325
+    if (getModifyTimeTargetFile(folderURL, timeFolder))
8076325
     {
8076325
-        if (itemFile.getFileStatus(statFile) == ::osl::File::E_None)
8076325
+        TimeValue timeFile;
8076325
+        if (getModifyTimeTargetFile(fileURL, timeFile))
8076325
         {
8076325
-            TimeValue timeFolder = statFolder.getModifyTime();
8076325
-            TimeValue timeFile = statFile.getModifyTime();
8076325
-
8076325
             if (timeFile.Seconds < timeFolder.Seconds)
8076325
                 bNeedsSync = true;
8076325
         }
8076325
@@ -204,6 +218,7 @@
8076325
         OSL_ASSERT(0);
8076325
         bNeedsSync = true;
8076325
     }
8076325
+
8076325
     return bNeedsSync;    
8076325
 }
8076325