]> granicus.if.org Git - file/commitdiff
Clarify documentation of search and regex matches, and sync with
authorReuben Thomas <rrt@sc3d.org>
Mon, 11 Feb 2008 23:26:17 +0000 (23:26 +0000)
committerReuben Thomas <rrt@sc3d.org>
Mon, 11 Feb 2008 23:26:17 +0000 (23:26 +0000)
actual behaviour of program.

doc/magic.man

index 98ed4f8bf5f765e86d389729dfc80041af79bcc0..cf6d01d0aae055a17718b9abbbd35efd235f8c92 100644 (file)
@@ -1,4 +1,4 @@
-.\" $File: magic.man,v 1.44 2008/02/08 13:09:56 christos Exp $
+.\" $File: magic.man,v 1.45 2008/02/11 22:14:25 rrt Exp $
 .Dd January 10, 2007
 .Dt MAGIC __FSECTION__
 .Os
@@ -149,16 +149,12 @@ than UTC.
 .It Dv regex
 A regular expression match in extended POSIX regular expression syntax
 (much like egrep).
-The type specification can be optionally followed by /[cse]*.
+The type specification can be optionally followed by /[c][s].
 The
 .Dq c
 flag makes the match case insensitive, while the
 .Dq s
-or
-.Dq e
-flags update the offset to the starting or ending offsets of the
-match (only one should be used).
-By default, regex does not update the offset.
+flag update the offset to the start offset of the match, rather than the end.
 The regular expression is tested against line
 .Dv N + 1
 onwards, where
@@ -179,7 +175,7 @@ which specifies how many matches shall be attempted (the range).
 This is suitable for searching larger binary expressions with variable
 offsets, using
 .Dv \e
-escapes for special characters.
+escapes for special characters. The offset works as for regex.
 .It Dv default
 This is intended to be used with the text
 .Dv x
@@ -478,4 +474,4 @@ a system on which the lengths are invariant.
 .\" the changes I posted to the S5R2 version.
 .\"
 .\" Modified for Ian Darwin's version of the file command.
-.\" @(#)$Id: magic.man,v 1.45 2008/02/11 22:14:25 rrt Exp $
+.\" @(#)$Id: magic.man,v 1.46 2008/02/11 23:26:17 rrt Exp $