[gvfs] afp: print better error message when trying to delete an open file



commit 1be385aad348629dfbedb9e15e0eecbc4308ab2c
Author: Carl-Anton Ingmarsson <ca ingmarsson gmail com>
Date:   Tue Aug 9 15:53:54 2011 +0200

    afp: print better error message when trying to delete an open file

 daemon/gvfsbackendafp.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/daemon/gvfsbackendafp.c b/daemon/gvfsbackendafp.c
index a2dd9f5..ae2ad3f 100644
--- a/daemon/gvfsbackendafp.c
+++ b/daemon/gvfsbackendafp.c
@@ -1167,6 +1167,10 @@ delete_cb (GObject *source_object, GAsyncResult *res, gpointer user_data)
         g_simple_async_result_set_error (simple, G_IO_ERROR, G_IO_ERROR_PERMISSION_DENIED,
                                   _("Permission denied"));
         break;
+      case AFP_RESULT_FILE_BUSY:
+        g_simple_async_result_set_error (simple, G_IO_ERROR, G_IO_ERROR_BUSY,
+                                         _("Target file is open"));
+        break;                           
       case AFP_RESULT_DIR_NOT_EMPTY:
         g_simple_async_result_set_error (simple, G_IO_ERROR, G_IO_ERROR_NOT_EMPTY,
                                   _("Directory not empty"));



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]