Bug 56299 - statserial -n /dev/ttyS0 doesn't produce any output
statserial -n /dev/ttyS0 doesn't produce any output
Product: Red Hat Linux
Classification: Retired
Component: statserial (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Tim Waugh
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-11-15 04:27 EST by Sxren Thing
Modified: 2007-04-18 12:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-11-16 07:52:57 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Sxren Thing 2001-11-15 04:27:01 EST
Description of Problem:
`statserial /dev/ttyS0' works OK, but when I use the -n option to disable 
looping I get exactly zero output. The return code is 0.
Options -d and -x seems to be OK.

Version-Release number of selected component (if applicable):
[root@localhost /]# rpm -q statserial

How Reproducible:
Every time

Steps to Reproduce:
1. I log in as root and use bash
2. I run the program.

Actual Results:
root@localhost /]# /usr/bin/statserial -n /dev/ttyS0
[root@localhost /]# echo $?
[root@localhost /]# /usr/bin/statserial -d /dev/ttyS0
[root@localhost /]# /usr/bin/statserial -x /dev/ttyS0
[root@localhost /]#

Expected Results:
I expected to see something like this:
Device: /dev/ttyS0

Signal  Pin  Pin  Direction  Status  Full
Name    (25) (9)  (computer)         Name
-----   ---  ---  ---------  ------  -----
FG       1    -      -           -   Frame Ground
TxD      2    3      out         -   Transmit Data
RxD      3    2      in          -   Receive  Data
RTS      4    7      out         1   Request To Send
CTS      5    8      in          0   Clear To Send
DSR      6    6      in          0   Data Set Ready
GND      7    5      -           -   Signal Ground
DCD      8    1      in          0   Data Carrier Detect
DTR     20    4      out         1   Data Terminal Ready
RI      22    9      in          0   Ring Indicator

Additional Information:
Also I wonder why the -d and -x options have the 0x4000-bit set in the 
Comment 1 Tim Waugh 2001-11-16 07:52:50 EST
This is to do with ncurses.  The call to endwin() restores the screen to its 
pre-initscr() state.  The only fix that comes to mind is just not to use 
ncurses when -n is given.

As for the 0x4000 bit: it's something to do with interrupts, I think.  Safe to 
Comment 2 Tim Waugh 2001-11-19 09:15:53 EST
Fixed in setserial-1.1-24.

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