Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 127285 - x11-terms/xterm - Backspace key not working properly when running screen with "lockscreen" option
Summary: x11-terms/xterm - Backspace key not working properly when running screen with...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Seemant Kulleen (RETIRED)
URL:
Whiteboard:
Keywords: NeedPatch
Depends on:
Blocks:
 
Reported: 2006-03-23 03:27 UTC by Arrigo Marchiori
Modified: 2007-12-26 10:51 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Arrigo Marchiori 2006-03-23 03:27:37 UTC
When I open an Xterm, then I launch screen, and the `lockscreen' option is set in my .screenrc, screen prompts for passwords and then shows the first window.

Only in this window, only in the shell, the backspace key doesn't delete one single character, but the whole line.

- if I launch vim, the backspace key works OK in vim. But if I close it and go back to the shell, the backspace starts working bad again.

- if I open a new screen window (^A C) then the backspace key works OK in _that_ screen's window

- if I launch screen from the console (e.g. tty1) everything works Ok

- if I comment out the "lockscreen" option in my .screenrc, the screen works Ok under Xterm too.

- when the backspace key doesn't work, then CTRL+Backspace works as a `good' Backspace

It looks like to me that this is some kind of issue between screen and xterm. This happens both with xterm and uxterm.

My locale is en_US.utf8

My screen version is 4.00.02 (FAU) 5-Dec-03.

When I launch screen, I'm asked both for my user password and for my screen password (the one specified in .screenrc)

My .screenrc is:

defc1 off
startup_message off
vbell on
escape ^A^A
password (encrypted password here)
lockscreen

emerge --info output:

Portage 2.0.54 (default-linux/x86/2006.0, gcc-3.4.5, glibc-2.3.5-r2, 2.6.15-gentoo-r1 i686)
=================================================================
System uname: 2.6.15-gentoo-r1 i686 Celeron (Coppermine)
Gentoo Base System version 1.6.14
dev-lang/python:     2.4.2
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O3 -march=pentium3 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=pentium3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="ftp://mirror.mcs.anl.gov/pub/gentoo/ http://www.die.unipd.it/pub/Linux/distributions/gentoo-sources/"
LANG="en_US.utf8"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://snail/gentoo-portage"
USE="x86 X Xaw3d a52 aac aalib acpi aim alsa apache2 apm arts audiofile avi bash-completion bcmath berkdb bitmap-fonts bzip2 cdparanoia cdr cli crypt ctype cups curl curlwrappers dba dbus dedicated dga doc dri dts dv dvb dvd dvdread eds emacs emboss encode esd ethereal exif expat fam fastbuild ffmpeg fftw flac flash foomaticdb force-cgi-redirect fortran ftp gd gdbm ggi gif glut gmp gnome gnutls gphoto2 gpm gstreamer gtk gtk2 gtkhtml guile hal iconv icq idn imagemagick imap imlib ipv6 jabber java javascript jpeg jpeg2k kde ladcca lcms leim lesstif libcaca libg++ libwww lm_sensors lua mad maildir matroska mbox mcal memlimit mhash mikmod mime ming mmap mmx mng motif mp3 mpeg msn mule mysql nas ncurses nls nptl nsplugin objc offensive ogg openal opengl oscar oss pam pcmcia pcre pda pdflib perl php plotutils png pop posix python qt quicktime readline recode samba sdl session sharedext sharedmem simplexml slang sndfile soap sockets socks5 sox speex spell spl sqlite sse ssl svg symlink sysvipc tcltk tcpd tetex theora threads tidy tiff tokenizer truetype truetype-fonts type1-fonts udev unicode usb vcd videos vorbis wifi win32codecs wmf wxwindows xface xine xml xml2 xmlrpc xmms xosd xpm xprint xsl xv xvid yahoo zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
Comment 1 Seemant Kulleen (RETIRED) gentoo-dev 2006-03-24 06:36:32 UTC
I have en_US.UTF8 as well, and I can see this with only 'lockscreen' in my .screenrc file.
Comment 2 Thomas Dickey 2006-08-01 14:06:01 UTC
I can't reproduce this (on Debian/testing), but it sounds as if screen
is updating its stty settings with its initial guess of stty erase as
^H rather than ^? (8 vs 127).  The "launch screen" sounds as if that's
done manually (or is it "xterm -e screen"?).
Comment 3 Emanuele Giaquinta (RETIRED) gentoo-dev 2006-08-15 14:45:47 UTC
I can reproduce it by adding lockscreen to .screenrc.
The problem is that kill is changed from ^U to ^H which triggers the reported behaviour when backspace sends ^H.
Comment 4 Thomas Dickey 2006-08-15 16:48:28 UTC
Grep'ing for KILL in the source, I see things like this (in InitTTY):

#if defined(VKILL)
#if (VKILL < MAXCC)
        m->tio.c_cc[VKILL]    = Ctrl('H');
#endif
#endif /* VKILL */

That would be executed if the ttyflag is zero, which can happen in a couple
of places (in TtyGrabConsole, and in ForkWindow).  The latter looks like a
recovery from some type of error.  screen has some debug traces that can be
activated if DEBUG is defined at compile-time.  You should be able to use that
to get more information about this.
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2007-12-26 10:51:28 UTC
Marking this upstream. Feel free to reopen once there's a patch available at
least.