[Bug 1621226] Re: grep does not output null when -o is used

Jarno Suni 1621226 at bugs.launchpad.net
Fri Nov 11 11:23:47 UTC 2016


** Description changed:

  testcase
  
- $ printf 'a\0b\0b1' | grep --null-data --null b | hexdump -C
+ $ printf 'a\0b\0b1' | grep --null-data b | hexdump -C
  00000000  62 00 62 31 00                                    |b.b1.|
  00000005
  
  but
  
- $ printf 'a\0b\0b1' | grep -o --null-data --null b | hexdump -C
+ $ printf 'a\0b\0b1' | grep -o --null-data b | hexdump -C
  00000000  62 0a 62 0a                                       |b.b.|
  00000004
  
  This is fixed in Xenial, but IMO should be fixed in Trusty, too.
  
  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: grep 2.16-1
  ProcVersionSignature: Ubuntu 4.4.0-37.56~14.04.1-generic 4.4.19
  Uname: Linux 4.4.0-37-generic x86_64
  ApportVersion: 2.14.1-0ubuntu3.21
  Architecture: amd64
  CurrentDesktop: XFCE
  Date: Wed Sep  7 22:48:42 2016
  EcryptfsInUse: Yes
  InstallationDate: Installed on 2014-09-21 (717 days ago)
  InstallationMedia: Ubuntu-Studio 14.04.1 LTS "Trusty Tahr" - Release amd64 (20140722.1)
  SourcePackage: grep
  UpgradeStatus: No upgrade log present (probably fresh install)

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to grep in Ubuntu.
https://bugs.launchpad.net/bugs/1621226

Title:
  grep does not output null when -o is used

Status in grep package in Ubuntu:
  New

Bug description:
  testcase

  $ printf 'a\0b\0b1' | grep --null-data b | hexdump -C
  00000000  62 00 62 31 00                                    |b.b1.|
  00000005

  but

  $ printf 'a\0b\0b1' | grep -o --null-data b | hexdump -C
  00000000  62 0a 62 0a                                       |b.b.|
  00000004

  This is fixed in Xenial, but IMO should be fixed in Trusty, too.

  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: grep 2.16-1
  ProcVersionSignature: Ubuntu 4.4.0-37.56~14.04.1-generic 4.4.19
  Uname: Linux 4.4.0-37-generic x86_64
  ApportVersion: 2.14.1-0ubuntu3.21
  Architecture: amd64
  CurrentDesktop: XFCE
  Date: Wed Sep  7 22:48:42 2016
  EcryptfsInUse: Yes
  InstallationDate: Installed on 2014-09-21 (717 days ago)
  InstallationMedia: Ubuntu-Studio 14.04.1 LTS "Trusty Tahr" - Release amd64 (20140722.1)
  SourcePackage: grep
  UpgradeStatus: No upgrade log present (probably fresh install)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/grep/+bug/1621226/+subscriptions



More information about the foundations-bugs mailing list