--- Begin Message ---
Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: unblock
Hi,
please unblock gvfs for the following changes.
gvfs (1.22.2-1) unstable; urgency=medium
* New upstream translation and bugfix release.
* fix-unmout-crash.patch: patch from upstream git. Fix crashes when
unmounting shares with pending operations.
* fix-cancellation: patch from upstream git. Fix user cancellation of
file operations.
I’m attaching the upstream changes between 1.22.1 and 1.22.2.
unblock gvfs/1.22.2-1
Cheers,
--
.''`. Josselin Mouette
: :' :
`. `'
`-
Index: debian/changelog
===================================================================
--- debian/changelog (révision 43977)
+++ debian/changelog (révision 43978)
@@ -1,3 +1,13 @@
+gvfs (1.22.2-1) unstable; urgency=medium
+
+ * New upstream translation and bugfix release.
+ * fix-unmout-crash.patch: patch from upstream git. Fix crashes when
+ unmounting shares with pending operations.
+ * fix-cancellation: patch from upstream git. Fix user cancellation of
+ file operations.
+
+ -- Josselin Mouette <joss@debian.org> Sun, 30 Nov 2014 22:18:27 +0100
+
gvfs (1.22.1-1) unstable; urgency=medium
* New upstream release.
Index: debian/patches/fix-cancellation.patch
===================================================================
--- debian/patches/fix-cancellation.patch (révision 0)
+++ debian/patches/fix-cancellation.patch (révision 43978)
@@ -0,0 +1,130 @@
+From 4b85af0d4a7ad69773839bd248284beb80e4bcac Mon Sep 17 00:00:00 2001
+From: Ross Lagerwall <rosslagerwall@gmail.com>
+Date: Sun, 8 Dec 2013 12:28:55 +0200
+Subject: client: Use the correct serial with file transfer cancellation
+
+When using Copy, Move, Push and Pull with progress callbacks, the
+progress callbacks increment the connection serial, so retrieve the
+serial immediately after the dbus method call so that the correct serial
+is used for cancellation.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=720058
+
+diff --git a/client/gdaemonfile.c b/client/gdaemonfile.c
+index c3f8284..5a1613f 100644
+--- a/client/gdaemonfile.c
++++ b/client/gdaemonfile.c
+@@ -2801,6 +2801,7 @@ file_transfer (GFile *source,
+ GVfsDBusProgress *progress_skeleton;
+ GFile *file1, *file2;
+ GError *my_error;
++ guint32 serial;
+
+ res = FALSE;
+ progress_skeleton = NULL;
+@@ -2808,6 +2809,7 @@ file_transfer (GFile *source,
+ source_is_daemon = G_IS_DAEMON_FILE (source);
+ dest_is_daemon = G_IS_DAEMON_FILE (destination);
+ send_progress = progress_callback != NULL;
++ serial = 0;
+
+ if (source_is_daemon && dest_is_daemon)
+ native_transfer = TRUE;
+@@ -2901,6 +2903,7 @@ retry:
+ cancellable,
+ copy_cb,
+ &data);
++ serial = g_dbus_connection_get_last_serial (connection);
+ g_main_loop_run (data.loop);
+ res = gvfs_dbus_mount_call_copy_finish (proxy, data.res, &my_error);
+ }
+@@ -2913,6 +2916,7 @@ retry:
+ cancellable,
+ copy_cb,
+ &data);
++ serial = g_dbus_connection_get_last_serial (connection);
+ g_main_loop_run (data.loop);
+ res = gvfs_dbus_mount_call_move_finish (proxy, data.res, &my_error);
+ }
+@@ -2929,6 +2933,7 @@ retry:
+ cancellable,
+ copy_cb,
+ &data);
++ serial = g_dbus_connection_get_last_serial (connection);
+ g_main_loop_run (data.loop);
+ res = gvfs_dbus_mount_call_push_finish (proxy, data.res, &my_error);
+ }
+@@ -2944,6 +2949,7 @@ retry:
+ cancellable,
+ copy_cb,
+ &data);
++ serial = g_dbus_connection_get_last_serial (connection);
+ g_main_loop_run (data.loop);
+ res = gvfs_dbus_mount_call_pull_finish (proxy, data.res, &my_error);
+ }
+@@ -2965,8 +2971,12 @@ retry:
+
+ if (! res)
+ {
+- if (proxy && g_error_matches (my_error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+- _g_dbus_send_cancelled_sync (g_dbus_proxy_get_connection (G_DBUS_PROXY (proxy)));
++ if (serial != 0 &&
++ g_error_matches (my_error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
++ {
++ _g_dbus_send_cancelled_with_serial_sync (g_dbus_proxy_get_connection (G_DBUS_PROXY (proxy)),
++ serial);
++ }
+ else
+ if (g_error_matches (my_error, G_VFS_ERROR, G_VFS_ERROR_RETRY))
+ {
+diff --git a/client/gvfsdaemondbus.c b/client/gvfsdaemondbus.c
+index dc5f50f..0bf47b1 100644
+--- a/client/gvfsdaemondbus.c
++++ b/client/gvfsdaemondbus.c
+@@ -418,14 +418,12 @@ _g_dbus_async_unsubscribe_cancellable (GCancellable *cancellable, gulong cancell
+ }
+
+ void
+- _g_dbus_send_cancelled_sync (GDBusConnection *connection)
++_g_dbus_send_cancelled_with_serial_sync (GDBusConnection *connection,
++ guint32 serial)
+ {
+- guint32 serial;
+ GVfsDBusDaemon *proxy;
+ GError *error = NULL;
+
+- serial = g_dbus_connection_get_last_serial (connection);
+-
+ proxy = gvfs_dbus_daemon_proxy_new_sync (connection,
+ G_DBUS_PROXY_FLAGS_NONE,
+ NULL,
+@@ -448,6 +446,13 @@ void
+ g_object_unref (proxy);
+ }
+
++void
++_g_dbus_send_cancelled_sync (GDBusConnection *connection)
++{
++ _g_dbus_send_cancelled_with_serial_sync (connection,
++ g_dbus_connection_get_last_serial (connection));
++}
++
+
+ /*************************************************************************
+ * get per-thread synchronous dbus connections *
+diff --git a/client/gvfsdaemondbus.h b/client/gvfsdaemondbus.h
+index 24f5056..bd02d41 100644
+--- a/client/gvfsdaemondbus.h
++++ b/client/gvfsdaemondbus.h
+@@ -67,6 +67,8 @@ gulong _g_dbus_async_subscribe_cancellable (GDBusConnection
+ void _g_dbus_async_unsubscribe_cancellable (GCancellable *cancellable,
+ gulong cancelled_tag);
+ void _g_dbus_send_cancelled_sync (GDBusConnection *connection);
++void _g_dbus_send_cancelled_with_serial_sync (GDBusConnection *connection,
++ guint32 serial);
+ void _g_propagate_error_stripped (GError **dest,
+ GError *src);
+ G_END_DECLS
+--
+cgit v0.10.1
+
Index: debian/patches/fix-unmount-crash.patch
===================================================================
--- debian/patches/fix-unmount-crash.patch (révision 0)
+++ debian/patches/fix-unmount-crash.patch (révision 43978)
@@ -0,0 +1,117 @@
+From 87c9f6d80ac612caedb7b39b22b3d4ed2804bb0b Mon Sep 17 00:00:00 2001
+From: Ross Lagerwall <rosslagerwall@gmail.com>
+Date: Sun, 28 Sep 2014 19:52:51 +0100
+Subject: gvfsjobunmount: Block new requests before calling unmount() on a
+ thread
+
+Block new requests before calling unmount() on a separate thread to
+prevent a race where new jobs are received and processed while the
+unmount() is being executed.
+
+This is not necessary for try_unmount() because all the job handling is
+done on the same thread as the try_unmount() method and requests are
+blocked when the try_unmount() method completes.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=710986
+
+diff --git a/daemon/gvfsbackend.c b/daemon/gvfsbackend.c
+index 299a9bd..ac84e35 100644
+--- a/daemon/gvfsbackend.c
++++ b/daemon/gvfsbackend.c
+@@ -590,9 +590,9 @@ g_vfs_backend_add_auto_info (GVfsBackend *backend,
+ }
+
+ void
+-g_vfs_backend_set_block_requests (GVfsBackend *backend)
++g_vfs_backend_set_block_requests (GVfsBackend *backend, gboolean value)
+ {
+- backend->priv->block_requests = TRUE;
++ backend->priv->block_requests = value;
+ }
+
+ gboolean
+@@ -1036,7 +1036,7 @@ forced_unregister_mount_callback (GVfsDBusMountTracker *proxy,
+ void
+ g_vfs_backend_force_unmount (GVfsBackend *backend)
+ {
+- g_vfs_backend_set_block_requests (backend);
++ g_vfs_backend_set_block_requests (backend, TRUE);
+ g_vfs_backend_unregister_mount (backend,
+ (GAsyncReadyCallback) forced_unregister_mount_callback,
+ backend);
+diff --git a/daemon/gvfsbackend.h b/daemon/gvfsbackend.h
+index 82c8283..1669c27 100644
+--- a/daemon/gvfsbackend.h
++++ b/daemon/gvfsbackend.h
+@@ -511,7 +511,8 @@ void g_vfs_backend_add_auto_info (GVfsBackend
+ GFileInfo *info,
+ const char *uri);
+
+-void g_vfs_backend_set_block_requests (GVfsBackend *backend);
++void g_vfs_backend_set_block_requests (GVfsBackend *backend,
++ gboolean value);
+ gboolean g_vfs_backend_get_block_requests (GVfsBackend *backend);
+
+ gboolean g_vfs_backend_unmount_with_operation_finish (GVfsBackend *backend,
+diff --git a/daemon/gvfsjobunmount.c b/daemon/gvfsjobunmount.c
+index 205407c..2108ddf 100644
+--- a/daemon/gvfsjobunmount.c
++++ b/daemon/gvfsjobunmount.c
+@@ -229,9 +229,12 @@ unmount_cb (GVfsBackend *backend,
+ op_job->flags,
+ op_job->mount_source);
+
+- if (run_in_thread)
+- g_vfs_daemon_run_job_in_thread (g_vfs_backend_get_daemon (backend),
+- G_VFS_JOB (op_job));
++ if (run_in_thread)
++ {
++ g_vfs_backend_set_block_requests (backend, TRUE);
++ g_vfs_daemon_run_job_in_thread (g_vfs_backend_get_daemon (backend),
++ G_VFS_JOB (op_job));
++ }
+ }
+ }
+
+@@ -265,7 +268,12 @@ try (GVfsJob *job)
+ op_job->flags,
+ op_job->mount_source);
+ else
+- return FALSE;
++ {
++ /* We're going to run the backend's unmount method on a thread, block
++ * new jobs coming in. */
++ g_vfs_backend_set_block_requests (backend, TRUE);
++ return FALSE;
++ }
+ }
+
+ static void
+@@ -304,18 +312,20 @@ static void
+ send_reply (GVfsJob *job)
+ {
+ GVfsJobUnmount *op_job = G_VFS_JOB_UNMOUNT (job);
++ GVfsBackend *backend = op_job->backend;
+
+ g_debug ("send_reply, failed: %d\n", job->failed);
+
+ if (job->failed)
+- (*G_VFS_JOB_CLASS (g_vfs_job_unmount_parent_class)->send_reply) (G_VFS_JOB (op_job));
++ {
++ g_vfs_backend_set_block_requests (backend, FALSE);
++ (*G_VFS_JOB_CLASS (g_vfs_job_unmount_parent_class)->send_reply) (G_VFS_JOB (op_job));
++ }
+ else
+ {
+- GVfsBackend *backend = op_job->backend;
+-
+ /* Setting the backend to block requests will also
+ set active GVfsChannels to block requets */
+- g_vfs_backend_set_block_requests (backend);
++ g_vfs_backend_set_block_requests (backend, TRUE);
+ g_vfs_backend_unregister_mount (backend,
+ (GAsyncReadyCallback) unregister_mount_callback,
+ job);
+--
+cgit v0.10.1
+
Index: debian/patches/series
===================================================================
--- debian/patches/series (révision 43977)
+++ debian/patches/series (révision 43978)
@@ -5,3 +5,5 @@
dont-crash-on-null-job.patch
handle-inactive-vfs.patch
ref-jobs-in-thread.patch
+fix-unmount-crash.patch
+fix-cancellation.patch
diff --git a/NEWS b/NEWS
index a1c41a4..c146220 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,10 @@
+Major changes in 1.22.2
+=======================
+* sftp: Correctly retrieve the username from the secret store
+* mtp: Fix crashes when device is unplugged
+* Several smaller bugfixes
+* Translation updates
+
Major changes in 1.22.1
=======================
* mtp: Improve transfer speed for large files
diff --git a/configure.ac b/configure.ac
index f1cd2bc..e9d7bbb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,6 @@
AC_PREREQ([2.64])
-AC_INIT([gvfs],[1.22.1],[http://bugzilla.gnome.org/enter_bug.cgi?product=gvfs])
+AC_INIT([gvfs],[1.22.2],[http://bugzilla.gnome.org/enter_bug.cgi?product=gvfs])
AM_INIT_AUTOMAKE([1.11.1 no-dist-gzip dist-xz tar-ustar -Wno-portability])
AC_CONFIG_HEADERS(config.h)
diff --git a/daemon/gvfsbackendmtp.c b/daemon/gvfsbackendmtp.c
index 8f1c4df..a606055 100644
--- a/daemon/gvfsbackendmtp.c
+++ b/daemon/gvfsbackendmtp.c
@@ -426,7 +426,11 @@ g_vfs_backend_mtp_finalize (GObject *object)
g_hash_table_foreach (backend->monitors, remove_monitor_weak_ref, backend->monitors);
g_hash_table_unref (backend->monitors);
- g_mutex_clear (&backend->mutex);
+
+ /* Leak the mutex if the backend is force unmounted to avoid crash caused by
+ * abort(), when trying to clear already locked mutex. */
+ if (!backend->force_unmounted)
+ g_mutex_clear (&backend->mutex);
(*G_OBJECT_CLASS (g_vfs_backend_mtp_parent_class)->finalize) (object);
@@ -602,6 +606,7 @@ on_uevent (GUdevClient *client, gchar *action, GUdevDevice *device, gpointer use
(char *)path);
}
+ op_backend->force_unmounted = TRUE;
g_vfs_backend_force_unmount ((GVfsBackend*)op_backend);
}
diff --git a/daemon/gvfsbackendmtp.h b/daemon/gvfsbackendmtp.h
index ce2159d..f477697 100644
--- a/daemon/gvfsbackendmtp.h
+++ b/daemon/gvfsbackendmtp.h
@@ -58,6 +58,7 @@ struct _GVfsBackendMtp
GHashTable *monitors;
guint hb_id;
gint unmount_started;
+ gboolean force_unmounted;
gboolean android_extension;
};
diff --git a/daemon/gvfsbackendsftp.c b/daemon/gvfsbackendsftp.c
index a81599e..55b2b48 100644
--- a/daemon/gvfsbackendsftp.c
+++ b/daemon/gvfsbackendsftp.c
@@ -950,7 +950,7 @@ handle_login (GVfsBackend *backend,
op_backend->port
:
0,
- NULL,
+ &new_user,
NULL,
&new_password)))
{
diff --git a/man/gvfs-mime.xml b/man/gvfs-mime.xml
index 01fd4b9..5cff3bd 100644
--- a/man/gvfs-mime.xml
+++ b/man/gvfs-mime.xml
@@ -35,7 +35,7 @@
<command>gvfs-mime --query <arg choice="req">MIMETYPE</arg></command>
</cmdsynopsis>
<cmdsynopsis>
- <command>gvfs-mime --set <arg choice="req">MIMETYPE</arg> <arg choice="req">HANDER</arg></command>
+ <command>gvfs-mime --set <arg choice="req">MIMETYPE</arg> <arg choice="req">HANDLER</arg></command>
</cmdsynopsis>
</refsynopsisdiv>
diff --git a/monitor/goa/goavolume.c b/monitor/goa/goavolume.c
index 83f038e..7db021a 100644
--- a/monitor/goa/goavolume.c
+++ b/monitor/goa/goavolume.c
@@ -179,7 +179,11 @@ mount_enclosing_volume_cb (GObject *source_object, GAsyncResult *res, gpointer u
}
else
{
- g_warning ("Already mounted %s: %s", g_file_get_uri (root), error->message);
+ gchar *uri;
+
+ uri = g_file_get_uri (root);
+ g_warning ("Already mounted %s: %s", uri, error->message);
+ g_free (uri);
g_error_free (error);
}
}
diff --git a/po/cs.po b/po/cs.po
index 89a0199..5f622cc 100644
diff --git a/po/de.po b/po/de.po
index b3a4a49..2ed6cc2 100644
diff --git a/po/es.po b/po/es.po
index 5dd805f..821b3fc 100644
diff --git a/po/hu.po b/po/hu.po
index cb6fbfd..2e697fa 100644
diff --git a/po/id.po b/po/id.po
index a653c4d..3d8d474 100644
diff --git a/po/lt.po b/po/lt.po
index 912c2ca..d062a08 100644
diff --git a/po/nb.po b/po/nb.po
index 60be34f..1fdd096 100644
diff --git a/po/pl.po b/po/pl.po
index 3a393a3..1a5a841 100644
diff --git a/po/sr.po b/po/sr.po
index a54603e..8e89d9e 100644
diff --git a/po/sr@latin.po b/po/sr@latin.po
index b469102..de87774 100644
diff --git a/po/uk.po b/po/uk.po
index 46f7b31..f33351b 100644
--- End Message ---