goa: Fix password-based authentication

https://bugzilla.redhat.com/show_bug.cgi?id=1461066
This commit is contained in:
Ondrej Holy 2017-07-19 17:12:39 +02:00
parent 9e6ea8185c
commit f4c919ac3a
2 changed files with 38 additions and 1 deletions

View File

@ -0,0 +1,30 @@
From 5fbae72a807dc0947143a4a65e7193cc24654108 Mon Sep 17 00:00:00 2001
From: Ondrej Holy <oholy@redhat.com>
Date: Wed, 19 Jul 2017 16:34:10 +0200
Subject: [PATCH] goa: Fix password-based authentication
Password-based authentication used for ownCloud/Nextcloud was broken
by GTask port (commit fdda284). GTask is used as user_data for async
callbacks currently, however, user_data is incorrectly cast to MountOp
in this case. Use g_task_get_task_data in order to fix this issue.
https://bugzilla.gnome.org/show_bug.cgi?id=780496
---
monitor/goa/goavolume.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/monitor/goa/goavolume.c b/monitor/goa/goavolume.c
index 00c7e541..c077dd94 100644
--- a/monitor/goa/goavolume.c
+++ b/monitor/goa/goavolume.c
@@ -105,7 +105,7 @@ mount_operation_ask_password_cb (GMountOperation *op,
GAskPasswordFlags flags,
gpointer user_data)
{
- MountOp *data = user_data;
+ MountOp *data = g_task_get_task_data (user_data);
g_mount_operation_set_password (data->mount_operation, data->passwd);
g_mount_operation_reply (data->mount_operation, G_MOUNT_OPERATION_HANDLED);
--
2.13.2

View File

@ -22,7 +22,7 @@
Name: gvfs
Version: 1.33.3
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Backends for the gio framework in GLib
License: GPLv3 and LGPLv2+ and BSD and MPLv2.0
@ -32,6 +32,9 @@ Source0: https://download.gnome.org/sources/gvfs/1.33/gvfs-%{version}.tar.xz
# http://bugzilla.gnome.org/show_bug.cgi?id=567235
Patch0: gvfs-archive-integration.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1461066
Patch1: goa-Fix-password-based-authentication.patch
BuildRequires: pkgconfig
BuildRequires: pkgconfig(glib-2.0) >= %{glib2_version}
BuildRequires: pkgconfig(dbus-glib-1)
@ -214,6 +217,7 @@ the functionality of the installed gvfs package.
%prep
%setup -q
%patch0 -p1 -b .archive-integration
%patch1 -p1 -b .goa-Fix-password-based-authentication
# Needed for gvfs-0.2.1-archive-integration.patch
autoreconf -fi
@ -407,6 +411,9 @@ killall -USR1 gvfsd >&/dev/null || :
%{_datadir}/installed-tests
%changelog
* Wed Jul 19 2017 Ondrej Holy <oholy@redhat.com> - 1.33.3-2
- goa: Fix password-based authentication (rhbz#1461066)
* Sun Jun 25 2017 Kalev Lember <klember@redhat.com> - 1.33.3-1
- Update to 1.33.3