#317068 rdesktop: Steals keyboard

Package:
rdesktop
Source:
rdesktop
Description:
RDP client for Windows NT/2000 Terminal Server and Windows Servers
Submitter:
Javier Kohen
Date:
2011-08-25 21:48:04 UTC
Severity:
normal
#317068#5
Date:
2005-07-05 23:46:10 UTC
From:
To:
RDesktop seems to grab the keyboard in a weird way while it's running. On one hand, it grabs alt-tab before the window manager which is useful, but on the other hand, it's a bit agressive. If the connection is lagging or gets disconnected (for some reason the window is not always closed), you lose all ability to use the keyboard. The only way I found to restore the keyboard to normal in this case is to kill rdesktop or wait until the connection gets back to normal (only if it wasn't lost, but severely lagged).

I expect that a lost connection or a slow network won't prevent me from typing in my local system once I take the focus away from rdesktop.

- -- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.12-ck2
Locale: LANG=es_AR.UTF-8, LC_CTYPE=es_AR.UTF-8 (charmap=UTF-8)

Versions of packages rdesktop depends on:
ii  libc6                    2.3.2.ds1-21    GNU C Library: Shared libraries an
ii  libssl0.9.7              0.9.7g-1        SSL shared libraries
ii  libx11-6                 4.3.0.dfsg.1-13 X Window System protocol client li
ii  xlibs                    4.3.0.dfsg.1-13 X Keyboard Extension (XKB) configu

rdesktop recommends no packages.

- -- no debconf information
iD8DBQFCyxvC823633cP2P8RAmolAJ9VDMwkei8vWyxqHodgHb5CV6fplgCeKTI1
7sI6JH/0aKwhki56jDsKgls=
=70Wo
-----END PGP SIGNATURE-----

#317068#10
Date:
2005-07-23 04:43:25 UTC
From:
To:
Javier Kohen skrev:

Hello Javier

Thank you for reporting this problem. I have not been able to
reproduce it myself, though. I have therefore presented your problem
to the rdesktop-devel mailing list. I will inform you of any
progress in this matter.

#317068#15
Date:
2005-07-28 09:01:01 UTC
From:
To:
I would like to confirm this problem and add a few notes, in case it is
of any help...

I don't know exactly how to provoke this behaviour, but it frequently
happens when connectivity has been poor or non-existant for a while and
the rdesktop window remains open. (Just like was described in the
original report.)

Usually, when the connection trouble starts, the rdesktop window just
stops updating (but keyboard can be used outside of rdesktop and
rdesktop can be closed normally). However, if you leave the window open,
the keyboard becomes unusable in the whole X session until rdesktop is
killed. Rdesktop also no longer responds to normally closing the window
when in this state.


Regards,
Håkan

#317068#20
Date:
2005-07-28 14:38:10 UTC
From:
To:
Håkan Lindqvist skrev:

Hej Håkan :)

What versions of rdesktop have been causing you this kind of trouble?

#317068#25
Date:
2005-07-28 14:53:46 UTC
From:
To:
Hej Tomas!

It must at least have been happening at least since 1.3.x, maybe longer
(it's even possible that rdesktop has always had this problem).

I'm currently using 1.4.1-1, which also does this.



/Håkan

#317068#30
Date:
2005-07-28 18:49:44 UTC
From:
To:
Håkan Lindqvist skrev:

Okej, tack. I will take it upstream and see what they have to say
about this. It is a bit strange that it has been there for such a
long time and not already been discovered and fixed.

#317068#35
Date:
2006-09-19 17:56:56 UTC
From:
To:
I'm seeing a similar behavior.  I connect over a vpn which sometimes
drops the connection or silently hangs.  I don't think you get any TCP
disconnects when this happens.  Once in this state, if I go into the
rdesktop window (which I believe has always been at a locked desktop
screen), it will take the keyboard and mouse but not give them back.
The mouse can move out of the window if it's not full screened, but I
cannot right click to close the rdesktop window and the keyboard is
completely taken.  Ssh'ing into the local machine and killing rdesktop
restores the keyboard and mouse.

For the rdesktop developers, I'd suggest adding a timeout on waiting for
a response from the server.  Also, make sure to accept focus changes and
changes in and out of full screen mode when the remote system is not
responsive.

Thanks for all your hard work!

#317068#40
Date:
2007-05-13 15:47:34 UTC
From:
To:
I'd like to confirm this bug is still in 1.5.0-1 .

It's hits me quite often unfortunately - and I'ld like to offer to
help debug it. It looks like rdesktop could be improved by
using non-blocking sockets or similiar.

I'm also going to mail upstream and make an offer there too.

#317068#45
Date:
2007-09-05 00:46:53 UTC
From:
To:
I would also like to summarise the problem the way I understand it:

If the mouse-pointer is inside the window and the window has focus,
the window grabs all keyboard-input. If this focus lasts for a while
when idling - let's say 5 minutes - and the local desktop screensaver
does not start - your mouse becomes useless and the RDP-session is
still grabbing the keyboard.

If you wait for your local screensaver to start, this usually solves
the problem.

I've grown aware on how to avoid it - just focus on other applications
when idling.

#317068#50
Date:
2010-12-05 09:05:53 UTC
From:
To:
Hi,

I can confirm this bug still happens on rdesktop 1.6.0-2  (Debian Lenny
i386).

As Trygve Vea said:

- It seems to happen afer idling with the focus on the rdesktop window.
- Firing up the screensaver usually solves the problem.

Another workaround is to remotely ssh into the machine and kill the
rdesktop process.

Best regards,

#317068#55
Date:
2011-08-25 20:42:52 UTC
From:
To:
Ubuntu has the same problem:

https://bugs.launchpad.net/debian/+source/rdesktop/+bug/81854

RedHat seems to have fixed it:

https://bugs.launchpad.net/debian/+source/rdesktop/+bug/81854/comments/26

Maybe they have a fix? What does upstream say about this problem? :

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=317068#30

Aparently an older version would not exhibit this bug (search for Ubuntu
7.04):

https://bugs.launchpad.net/ubuntu/+source/rdesktop/+bug/218308/comments/7

I've reported the bug here upstream:

https://sourceforge.net/tracker/index.php?func=detail&aid=3398169&group_id=24366&atid=381347

*t