[pkg-gnupg-maint] Bug#850708: Bug#850708: gpg: decryption failed: No secret key
Vincent Lefevre
vincent at vinc17.net
Wed Jan 11 11:22:55 UTC 2017
Control: tags -1 patch
On 2017-01-11 11:45:07 +0100, Vincent Lefevre wrote:
> In pinentry-gtk-2.c:
>
> do
> err = gdk_pointer_grab (gtk_widget_get_window (win),
> TRUE, 0 /* event mask */,
> NULL /* confine to */,
> cursor,
> gdk_event_get_time (event));
> while (tries++ < max_tries && err == GDK_GRAB_NOT_VIEWABLE);
>
> Between the calls to gdk_pointer_grab, the pinentry should wait
> a little time.
This wasn't the problem. The problem was the incorrect error code:
GDK_GRAB_NOT_VIEWABLE instead of GDK_GRAB_ALREADY_GRABBED
(GDK_GRAB_NOT_VIEWABLE was for the keyboard grab apparently).
The attached patch solves the problem for me.
--
Vincent Lefèvre <vincent at vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
-------------- next part --------------
Index: pinentry-1.0.0/gtk+-2/pinentry-gtk-2.c
===================================================================
--- pinentry-1.0.0.orig/gtk+-2/pinentry-gtk-2.c
+++ pinentry-1.0.0/gtk+-2/pinentry-gtk-2.c
@@ -215,7 +215,7 @@ grab_pointer (GtkWidget *win, GdkEvent *
NULL /* confine to */,
cursor,
gdk_event_get_time (event));
- while (tries++ < max_tries && err == GDK_GRAB_NOT_VIEWABLE);
+ while (tries++ < max_tries && err == GDK_GRAB_ALREADY_GRABBED);
if (err)
{
More information about the pkg-gnupg-maint
mailing list