OSSP CVS Repository

ossp - Check-in [3515]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 3515
Date: 2003-Jul-11 16:03:53 (local)
2003-Jul-11 14:03:53 (UTC)
User:ms
Branch:
Comment: Back out regex fix, because the changed PCRE PCRE_DOLLAR_ENDONLY flag broke rc file parsing.
Tickets:
Inspections:
Files:
ossp-pkg/rc/rc_const.h      1.38 -> 1.39     1 inserted, 1 deleted
ossp-pkg/rc/rc_file.c      1.7 -> 1.8     1 inserted, 1 deleted
ossp-pkg/rc/rc_script.c      1.36 -> 1.37     1 inserted, 1 deleted

ossp-pkg/rc/rc_const.h 1.38 -> 1.39

--- rc_const.h   2003/07/11 13:47:13     1.38
+++ rc_const.h   2003/07/11 14:03:53     1.39
@@ -157,7 +157,7 @@
 #define RC_DEF_ON     "1"                       /* Digital switch */
 #define RC_DEF_OFF    "0"                       /* Digital switch */
 #define RC_DEF_TMP    "/tmp"                    /* Temporary directory name */
-#define RC_DEF_DEF    "(?:^|\\n)%(\\w+)[ \\t]*(.*?)\\n(.*?)(?:\\n%|$)" /* Section definition */
+#define RC_DEF_DEF    "^%(\\w+)[ \t]*(.*?)\\n(.*?)^$" /* Section definition */
 #define RC_DEF_NCF    "config"                  /* Config section name */
 #define RC_DEF_CMN    "common"                  /* Common section name */
 #define RC_DEF_UIG    "-u"                      /* Section user string */


ossp-pkg/rc/rc_file.c 1.7 -> 1.8

--- rc_file.c    2003/07/11 08:49:36     1.7
+++ rc_file.c    2003/07/11 14:03:53     1.8
@@ -149,7 +149,7 @@
         int nSubstrings    = 0;
         int *pnVec         = NULL;
         const char *kszErr = NULL;
-        const int kiRegopt = PCRE_DOTALL | PCRE_DOLLAR_ENDONLY;
+        const int kiRegopt = PCRE_DOTALL | PCRE_MULTILINE;
         /*const int kiRegopt = PCRE_DOTALL | PCRE_MULTILINE | PCRE_UNGREEDY;*/
 
         pcre *pRegex       = NULL;  /* Perl Compatible Regular Expression */


ossp-pkg/rc/rc_script.c 1.36 -> 1.37

--- rc_script.c  2003/07/11 08:49:36     1.36
+++ rc_script.c  2003/07/11 14:03:53     1.37
@@ -178,7 +178,7 @@
     int nSubstrings    = 0;
     int *pnVec         = NULL;
     const char *kszErr = NULL;
-    const int kiRegopt = PCRE_DOTALL | PCRE_DOLLAR_ENDONLY;
+    const int kiRegopt = PCRE_DOTALL | PCRE_MULTILINE;
 /*    const int kiRegopt = PCRE_DOTALL | PCRE_MULTILINE | PCRE_UNGREEDY;*/
 
     pcre *pRegex       = NULL;  /* Perl Compatible Regular Expression */

CVSTrac 2.0.1