New SQLite version
[pithos-ms-client] / trunk / Pithos.Core / Agents / Uploader.cs
index 87c4dc3..db0735e 100644 (file)
@@ -129,7 +129,7 @@ namespace Pithos.Core.Agents
                                 await UploadWithHashMap(accountInfo, cloudFile, fileInfo as FileInfo, cloudFile.Name, treeHash);
                             }
                             //If everything succeeds, change the file and overlay status to normal
-                            StatusKeeper.SetFileState(fullFileName, FileStatus.Unchanged, FileOverlayStatus.Normal);
+                            StatusKeeper.SetFileState(fullFileName, FileStatus.Unchanged, FileOverlayStatus.Normal, "");
                         }
                         catch (WebException exc)
                         {
@@ -138,11 +138,11 @@ namespace Pithos.Core.Agents
                                 throw;
                             if (response.StatusCode == HttpStatusCode.Forbidden)
                             {
-                                StatusKeeper.SetFileState(fileInfo.FullName, FileStatus.Forbidden, FileOverlayStatus.Conflict);
+                                StatusKeeper.SetFileState(fileInfo.FullName, FileStatus.Forbidden, FileOverlayStatus.Conflict, "Forbidden");
                             }
-
-                            //In any other case, propagate the error
-                            throw;
+                            else
+                                //In any other case, propagate the error
+                                throw;
                         }
                     }
                     //Notify the Shell to update the overlays
@@ -274,7 +274,7 @@ namespace Pithos.Core.Agents
             {
                 Log.Error("Not allowed to upload file", exc);
                 var message = String.Format("Not allowed to uplad file {0}", action.LocalFile.FullName);
-                StatusKeeper.SetFileState(action.LocalFile.FullName, FileStatus.Unchanged, FileOverlayStatus.Normal);
+                StatusKeeper.SetFileState(action.LocalFile.FullName, FileStatus.Unchanged, FileOverlayStatus.Normal, "");
                 StatusNotification.NotifyChange(message, TraceLevel.Warning);
                 return true;
             }