summaryrefslogtreecommitdiff
path: root/pcregrep.c
diff options
context:
space:
mode:
authorph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2011-01-15 11:31:39 +0000
committerph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2011-01-15 11:31:39 +0000
commit076d2153a38327a35ed525cd6e18ab878ee5732d (patch)
tree2d521f37d6ca3e620fdaa57ac713cf17080ba8a3 /pcregrep.c
parent1482ba5c96cf56eadaf32e150e989ce8975a3eaf (diff)
downloadpcre-076d2153a38327a35ed525cd6e18ab878ee5732d.tar.gz
Tidies for Release 8.12
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@589 2f5784b3-3f2a-0410-8824-cb99058d5e15
Diffstat (limited to 'pcregrep.c')
-rw-r--r--pcregrep.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/pcregrep.c b/pcregrep.c
index f01833d..9b63eae 100644
--- a/pcregrep.c
+++ b/pcregrep.c
@@ -1349,10 +1349,10 @@ while (ptr < endptr)
/* We have to split the line(s) up if colouring, and search for further
matches, but not of course if the line is a non-match. */
-
+
if (do_colour && !invert)
{
- int plength;
+ int plength;
int last_offset = 0;
FWRITE(ptr, 1, offsets[0], stdout);
fprintf(stdout, "%c[%sm", 0x1b, colour_string);
@@ -1372,9 +1372,9 @@ while (ptr < endptr)
}
/* In multiline mode, we may have already printed the complete line
- and its line-ending characters (if they matched the pattern), so there
+ and its line-ending characters (if they matched the pattern), so there
may be no more to print. */
-
+
plength = (linelength + endlinelength) - last_offset;
if (plength > 0)
FWRITE(ptr + last_offset, 1, plength, stdout);