grep-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

grep branch, master, updated. v2.6.3-56-g42ac56a


From: Paolo Bonzini
Subject: grep branch, master, updated. v2.6.3-56-g42ac56a
Date: Tue, 20 Apr 2010 12:06:13 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "grep".

The branch, master has been updated
       via  42ac56a136085b0fb4dd4c627436b051c922ceb8 (commit)
       via  0a7b816b088a3a6ddc9a90cfcb728757593fb442 (commit)
      from  b464ff9368acc72fdbe4cb749786028e78a66299 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/grep.git/commit/?id=42ac56a136085b0fb4dd4c627436b051c922ceb8


commit 42ac56a136085b0fb4dd4c627436b051c922ceb8
Author: Paolo Bonzini <address@hidden>
Date:   Tue Apr 20 14:04:14 2010 +0200

    dfa: honor RE_DOT_NEWLINE and RE_DOT_NOT_NULL in UTF-8 period optimization
    
    * src/dfa.c (add_utf8_anychar): Check for RE_DOT_NEWLINE and
    RE_DOT_NOT_NULL.

diff --git a/src/dfa.c b/src/dfa.c
index 7d39e5c..340a4c6 100644
--- a/src/dfa.c
+++ b/src/dfa.c
@@ -1487,7 +1487,18 @@ add_utf8_anychar (void)
   /* Define the five character classes that are needed below.  */
   if (dfa->utf8_anychar_classes[0] == 0)
     for (i = 0; i < n; i++)
-      dfa->utf8_anychar_classes[i] = CSET + charclass_index(utf8_classes[i]);
+      {
+        charclass c;
+        memcpy (c, utf8_classes[i], sizeof c);
+        if (i == 1)
+          {
+            if (!(syntax_bits & RE_DOT_NEWLINE))
+              clrbit (eolbyte, c);
+            if (syntax_bits & RE_DOT_NOT_NULL)
+              clrbit ('\0', c);
+          }
+        dfa->utf8_anychar_classes[i] = CSET + charclass_index(c);
+      }
 
   /* A valid UTF-8 character is
 

http://git.savannah.gnu.org/cgit/grep.git/commit/?id=0a7b816b088a3a6ddc9a90cfcb728757593fb442


commit 42ac56a136085b0fb4dd4c627436b051c922ceb8
Author: Paolo Bonzini <address@hidden>
Date:   Tue Apr 20 14:04:14 2010 +0200

    dfa: honor RE_DOT_NEWLINE and RE_DOT_NOT_NULL in UTF-8 period optimization
    
    * src/dfa.c (add_utf8_anychar): Check for RE_DOT_NEWLINE and
    RE_DOT_NOT_NULL.

diff --git a/src/dfa.c b/src/dfa.c
index 7d39e5c..340a4c6 100644
--- a/src/dfa.c
+++ b/src/dfa.c
@@ -1487,7 +1487,18 @@ add_utf8_anychar (void)
   /* Define the five character classes that are needed below.  */
   if (dfa->utf8_anychar_classes[0] == 0)
     for (i = 0; i < n; i++)
-      dfa->utf8_anychar_classes[i] = CSET + charclass_index(utf8_classes[i]);
+      {
+        charclass c;
+        memcpy (c, utf8_classes[i], sizeof c);
+        if (i == 1)
+          {
+            if (!(syntax_bits & RE_DOT_NEWLINE))
+              clrbit (eolbyte, c);
+            if (syntax_bits & RE_DOT_NOT_NULL)
+              clrbit ('\0', c);
+          }
+        dfa->utf8_anychar_classes[i] = CSET + charclass_index(c);
+      }
 
   /* A valid UTF-8 character is
 

-----------------------------------------------------------------------

Summary of changes:
 NEWS       |    3 +++
 src/dfa.c  |   13 ++++++++++++-
 src/main.c |    1 +
 3 files changed, 16 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
grep




reply via email to

[Prev in Thread] Current Thread [Next in Thread]