[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Utility grep
From: |
James |
Subject: |
Utility grep |
Date: |
Sat, 14 Jan 2012 16:44:59 +0100 |
Hi,
I was looking for a tool that could find a string (pattern) in a file
and return the startposition of each occurence.
I tested GREP with the -b option
It works fine if the file is a text file, but it does not returns the
binary position of the searchpattern, but the binary position of the
beginning of the LINE where it is part of ...
Furtermore, if the file is an EXE, so a real binary file and not a
text file with lines, this does not work.
If I use the parameter "-c", I get the correct number of occurences.
But without this parameter, it just says "Binary file filename.exe
matches"
Is it not possible to get the startposition of each occurence of a
pattern in a non text file ?
James
mailto:address@hidden