Bug 23258 - -w and -W options break when output is not a tty
Summary: -w and -W options break when output is not a tty
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: man   
(Show other bugs)
Version: 6.2
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Bernhard Rosenkraenzer
QA Contact: Aaron Brown
Depends On:
TreeView+ depends on / blocked
Reported: 2001-01-03 23:58 UTC by Need Real Name
Modified: 2007-03-27 03:38 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-01-03 23:58:10 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Need Real Name 2001-01-03 23:58:07 UTC
The -w and -W options behave differently and produce different output when 
the stdout is a tty tty than when it is not, e.i. 

$ man -W info

$ man -W info | cat

$ man -W info | more

I haven't checked the source code, but I imagine that there is a test 
for 'isatty' early in the man program to determine whether or not to 
utilize the preformatted 'catman' pages.  This test should always be true 
when the -W or -w options are in effect, otherwise it is easy to miss the 
source of corrupted man pages.

Incidentally, the 'man' manpage mentions the ability redirect the output 
of -W but does not say anything about the fact that the output will be 
*different* than if you just let it go to a terminal.  I don't think the 
man page is incorrect for this oversight; I think the behavior is broken.

Comment 1 Bernhard Rosenkraenzer 2001-04-25 09:06:45 UTC
Fixed in 1.5i-1

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