I think I already posted something about it. When switching between remote desktop and local one it is not unusual to miss a key release event and, as so, until I press CNTRL or ALT the keyboard input acts like it was (CNTRL|ALT)+key pressed. I think it is possible to overcame this issue if we take in account some time interval because X keeps sending press events regularly. If we don't see them it is almost sure that release event was missed.
If there is no one investigating it I may step in.
I think I already posted something about it. When switching between remote desktop and local one it is not unusual to miss a key release event and, as so, until I press CNTRL or ALT the keyboard input acts like it was (CNTRL|ALT)+key pressed. I think it is possible to overcame this issue if we take in account some time interval because X keeps sending press events regularly. If we don't see them it is almost sure that release event was missed.
If there is no one investigating it I may step in.
Best regards, André