summaryrefslogtreecommitdiff
path: root/pcreposix.c
diff options
context:
space:
mode:
authornigel <nigel@2f5784b3-3f2a-0410-8824-cb99058d5e15>2007-02-24 21:40:37 +0000
committernigel <nigel@2f5784b3-3f2a-0410-8824-cb99058d5e15>2007-02-24 21:40:37 +0000
commit455fcc7e13a175722acfd2cca6ab99caa9606a22 (patch)
tree6561516fd308ce5b1b077797ad2f508701014cc6 /pcreposix.c
parent568064fe47fac0c7caffc684e6ea227ad8127b70 (diff)
downloadpcre-455fcc7e13a175722acfd2cca6ab99caa9606a22.tar.gz
Load pcre-5.0 into code/trunk.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@75 2f5784b3-3f2a-0410-8824-cb99058d5e15
Diffstat (limited to 'pcreposix.c')
-rw-r--r--pcreposix.c53
1 files changed, 32 insertions, 21 deletions
diff --git a/pcreposix.c b/pcreposix.c
index 856c97b..1e8b6a7 100644
--- a/pcreposix.c
+++ b/pcreposix.c
@@ -12,26 +12,34 @@ functions.
Written by: Philip Hazel <ph10@cam.ac.uk>
- Copyright (c) 1997-2003 University of Cambridge
+ Copyright (c) 1997-2004 University of Cambridge
-----------------------------------------------------------------------------
-Permission is granted to anyone to use this software for any purpose on any
-computer system, and to redistribute it freely, subject to the following
-restrictions:
-
-1. This software is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-
-2. The origin of this software must not be misrepresented, either by
- explicit claim or by omission.
-
-3. Altered versions must be plainly marked as such, and must not be
- misrepresented as being the original software.
-
-4. If PCRE is embedded in any software that is released under the GNU
- General Purpose Licence (GPL), then the terms of that licence shall
- supersede any condition above with which it is incompatible.
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright notice,
+ this list of conditions and the following disclaimer.
+
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ * Neither the name of the University of Cambridge nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
-----------------------------------------------------------------------------
*/
@@ -48,7 +56,7 @@ static const char *const estring[] = {
ERR11, ERR12, ERR13, ERR14, ERR15, ERR16, ERR17, ERR18, ERR19, ERR20,
ERR21, ERR22, ERR23, ERR24, ERR25, ERR26, ERR27, ERR29, ERR29, ERR30,
ERR31, ERR32, ERR33, ERR34, ERR35, ERR36, ERR37, ERR38, ERR39, ERR40,
- ERR41, ERR42, ERR43, ERR44 };
+ ERR41, ERR42, ERR43, ERR44, ERR45, ERR46, ERR47 };
static const int eint[] = {
REG_EESCAPE, /* "\\ at end of pattern" */
@@ -87,14 +95,17 @@ static const int eint[] = {
REG_BADPAT, /* "character value in \x{...} sequence is too large" */
REG_BADPAT, /* "invalid condition (?(0)" */
REG_BADPAT, /* "\\C not allowed in lookbehind assertion" */
- REG_EESCAPE, /* "PCRE does not support \\L, \\l, \\N, \\P, \\p, \\U, \\u, or \\X" */
+ REG_EESCAPE, /* "PCRE does not support \\L, \\l, \\N, \\U, or \\u" */
REG_BADPAT, /* "number after (?C is > 255" */
REG_BADPAT, /* "closing ) for (?C expected" */
REG_BADPAT, /* "recursive call could loop indefinitely" */
REG_BADPAT, /* "unrecognized character after (?P" */
REG_BADPAT, /* "syntax error after (?P" */
REG_BADPAT, /* "two named groups have the same name" */
- REG_BADPAT /* "invalid UTF-8 string" */
+ REG_BADPAT, /* "invalid UTF-8 string" */
+ REG_BADPAT, /* "support for \\P, \\p, and \\X has not been compiled" */
+ REG_BADPAT, /* "malformed \\P or \\p sequence" */
+ REG_BADPAT /* "unknown property name after \\P or \\p" */
};
/* Table of texts corresponding to POSIX error codes */