Bug 138000 - when switching from an X console to a non-X console, something is interpreting the cursor visibility state of the switched-to console as applying to all other consoles if the visibility state of the switched-to console is hidden, but not if the state i...
Summary: when switching from an X console to a non-X console, something is interpretin...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: 3
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Dave Jones
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-11-03 18:24 UTC by Daniel Reed
Modified: 2022-08-10 16:08 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-10-06 04:06:00 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Daniel Reed 2004-11-03 18:24:34 UTC
Version-Release number of selected component (if applicable):
kernel-2.6.9-1.649

How reproducible:
Every time

Steps to Reproduce:
Compile this C code as curs_set, -lncurses:
#include <ncurses.h>

int     main(int argc, char **args) {
        initscr();
        curs_set(atoi(args[1]));
        while (1)
                sleep(100);
        return(0);
}

Run ./curs_set 0 in tty4
Note that the cursor disappears.
Switch to X on tty7
Switch to tty5, note that the cursor is still blinking. Switch to tty4, note
that the cursor is correctly not blinking. Switch to tty5 again and not it is
still correctly blinking.
Switch to X on tty7
Switch directly to tty4. The cursor is correctly not blinking. Switch to tty5.
Note that the cursor is incorrectly also not blinking.

It appears that, when switching from an X console to a non-X console, something
is interpreting the cursor visibility state of the switched-to console as
applying to all other consoles if the visibility state of the switched-to
console is hidden, but not if the state is underscore (./curs_set 1) or block
(./curs_set 2).

Moving tty4 from curs_set 0 back to the default (by hitting ^C while curs_set is
running, flipping to another pty in screen on that terminal, etc.) is enough to
restore all other terminals' cursors (it "breaks the curse" so to speak).
Running ./curs_set 1 on any other terminal is also enough to break the curse
(without affecting tty4's hidden state).

Comment 1 Daniel Reed 2008-08-02 20:16:37 UTC
The original summary for this bug was longer than 255 characters, and so it was truncated when Bugzilla was upgraded. The original summary was:

when switching from an X console to a non-X console, something is interpreting the cursor visibility state of the switched-to console as applying to all other consoles if the visibility state of the switched-to console is hidden, but not if the state is underscore or block


Note You need to log in before you can comment on or make changes to this bug.