lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090709082651.GA6165@streefland.net>
Date:	Thu, 9 Jul 2009 10:26:51 +0200
From:	Dick Streefland <dick@...eefland.net>
To:	Amerigo Wang <xiyou.wangcong@...il.com>
Cc:	linux-kbuild@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] kconfig: simplification of scripts/extract-ikconfig

On Thursday 2009-07-09 10:38, Amerigo Wang wrote:
| I appologize for my delay, I totally missed this thread, sorry.
| 
| I just tested it, it works! So,
| 
| Tested-by: WANG Cong <xiyou.wangcong@...il.com>

Great, thanks.

| But, I still don't understand the behavior of 'grep -abo',
| please try the following commands:
| 
| echo -e '\x01\x02\x03\x04' > test.bin
| od -x test.bin
| tr $'\x01\x02\x03\x04' '1234' < test.bin | grep -abo '4'
| 
| Am I missing something here??

The output with grep-2.5.3 is 3:4, which means that the string "4" was
found at offset 3 (0-based). With grep-2.5.1, you get 0:4, which means
that the line containing the string "4" has offset 0. The "tr" commands
in the script ensure that the patterns we are looking for are always at
the start of a line, so that it doesn't matter which version of grep is
installed.

-- 
Dick
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ