[gvfs/ftp-reorg: 4/15] [FTP] properly reduce connection count when freeing connection



commit 4a102eceecc0dd86e8f440a7a17f0ada51c3214c
Author: Benjamin Otte <otte gnome org>
Date:   Thu Jun 4 18:33:39 2009 +0200

    [FTP] properly reduce connection count when freeing connection
---
 daemon/gvfsftptask.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/daemon/gvfsftptask.c b/daemon/gvfsftptask.c
index af889fe..c236817 100644
--- a/daemon/gvfsftptask.c
+++ b/daemon/gvfsftptask.c
@@ -283,7 +283,10 @@ g_vfs_ftp_task_release_connection (GVfsFtpTask *task)
       g_cond_signal (task->backend->cond);
     }
   else
-    g_vfs_ftp_connection_free (task->conn);
+    {
+      task->backend->connections--;
+      g_vfs_ftp_connection_free (task->conn);
+    }
   g_mutex_unlock (task->backend->mutex);
   task->conn = NULL;
 }



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