GNU bug report logs - #33774
glitch in cat

Previous Next

Package: coreutils;

Reported by: Valentin Schild <valentinschild <at> gmail.com>

Date: Sun, 16 Dec 2018 22:11:02 UTC

Severity: normal

Tags: notabug

Done: Bernhard Voelker <mail <at> bernhard-voelker.de>

Bug is archived. No further changes may be made.

Full log


Message #10 received at control <at> debbugs.gnu.org (full text, mbox):

From: Bernhard Voelker <mail <at> bernhard-voelker.de>
To: Valentin Schild <valentinschild <at> gmail.com>, 33774 <at> debbugs.gnu.org
Subject: Re: bug#33774: glitch in cat
Date: Wed, 19 Dec 2018 14:01:38 +0100
tags 33774 notabug
close 33774
stop

On 12/16/18 8:58 PM, Valentin Schild wrote:
> somehow, when using cat to display a file's content, I get output to
> the command line
> The file to output contains
> ^[Z
> like attached file "catbug".
> 
> In terminal I type
> cat catbug

That's the point: the terminal treats some control characters specially,
and therefore does not display them.

Your file contains 3 bytes:
- octal 33,
- a 'Z', and
- octal 12 (=newline):

  od -to1z catbug
  0000000 033 132 012                                                      >.Z.<
  0000003

And cat(1) is exactly writing that to the terminal:

  $ strace -ve write cat catbug
  write(1, "\33Z\n", 3)                   = 3
  +++ exited with 0 +++

As there seems nothing to be wrong in 'cat', I'm marking this as not a bug
in our bug tracker.  Of course, discussion on this may continue, and we may
even re-open this issue if needed.

Have a nice day,
Berny





This bug report was last modified 6 years and 150 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.