summaryrefslogtreecommitdiffstats
path: root/usr.bin/grep/fastgrep.c
diff options
context:
space:
mode:
authorgabor <gabor@FreeBSD.org>2011-04-07 13:03:35 +0000
committergabor <gabor@FreeBSD.org>2011-04-07 13:03:35 +0000
commit43c556e7f5fa602b4371c67d025ddeac54fea2c2 (patch)
tree8ecb3f60fd533d0351430eaddfdda19a381e12e4 /usr.bin/grep/fastgrep.c
parent43d1fb6126cdbf87fca36832fc399143e021ad7c (diff)
downloadFreeBSD-src-43c556e7f5fa602b4371c67d025ddeac54fea2c2.zip
FreeBSD-src-43c556e7f5fa602b4371c67d025ddeac54fea2c2.tar.gz
- Adjust a comment to actual behaviour
- Makefile nit - Add more CVS/SVN keywords to make it easier to track changes from NetBSD in case they add further improvements Approved by: delphij (mentor) Obtained from: The NetBSD Project
Diffstat (limited to 'usr.bin/grep/fastgrep.c')
-rw-r--r--usr.bin/grep/fastgrep.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/grep/fastgrep.c b/usr.bin/grep/fastgrep.c
index 442ff4c..d5c9d31 100644
--- a/usr.bin/grep/fastgrep.c
+++ b/usr.bin/grep/fastgrep.c
@@ -1,4 +1,6 @@
/* $OpenBSD: util.c,v 1.36 2007/10/02 17:59:18 otto Exp $ */
+/* $NetBSD: fastgrep.c,v 1.4 2011/02/27 17:33:37 joerg Exp $ */
+/* $FreeBSD$ */
/*-
* Copyright (c) 1999 James Howard and Dag-Erling Coïdan Smørgrav
@@ -112,9 +114,9 @@ fastcomp(fastgrep_t *fg, const char *pat)
}
/*
- * Copy pattern minus '^' and '$' characters as well as word
- * match character classes at the beginning and ending of the
- * string respectively.
+ * pat has been adjusted earlier to not include '^', '$' or
+ * the word match character classes at the beginning and ending
+ * of the string respectively.
*/
fg->pattern = grep_malloc(fg->len + 1);
memcpy(fg->pattern, pat, fg->len);
OpenPOWER on IntegriCloud