Home | History | Annotate | Download | only in regex
History log of /src/lib/libc/regex/engine.c
RevisionDateAuthorComments
 1.30  23-Jan-2024  christos handle sizeof(off_t) > sizeof(size_t)
 1.29  25-Feb-2021  christos fix NLS compilation
 1.28  25-Feb-2021  christos Add glue to disable locale code in order to be smaller.
 1.27  24-Feb-2021  christos reduce casts
 1.26  24-Feb-2021  wiz Restore NetBSD RCS Ids.
 1.25  23-Feb-2021  christos sync with FreeBSD:
- NLS support
- GNU extensions
- bug fixes
 1.24  13-Mar-2012  christos PR/45989: Martin Husemann: lint invocation does include -w only on i386

- turn lint -w for all the platforms after fixing the lint warnings.
- add _DIAGASSERTS() for casts that would assign values to types that
would not fit.
- change types, add casts
- change into ansii prototypes
- turn on _DIAGNOSTIC for libc (during current, to be eliminated for release
builds)

approved by core@
 1.23  09-Oct-2011  christos branches: 1.23.2;
Prevent regcomp/regexec DoS attacks by limiting the amount of memory used
and the level of recursion. Thanks to Maksymilian Arciemowicz for discovery
and help with the implementation.
 1.22  12-Feb-2009  lukem sign-compare fixes
 1.21  08-Feb-2007  junyoung branches: 1.21.22;
ANSIfy.
 1.20  08-Feb-2007  junyoung Nuke __P.
 1.19  02-Dec-2005  yamt constify and remove __UNCONST.
 1.18  03-Apr-2004  christos Avoid infinite recursion on:

echo "foo foo bar bar bar baz" | sed 's/\([^ ]*\)\( *\1\)*/\1/g'

From OpenBSD.
 1.17  26-Mar-2004  enami Redo previous in a different way; cast the character held in int variable
as unsigned char just before passing isalnum() in ISWORD() rather than
fetching it as unsigned char. It is ok since EOF is never passed to ISWORD()
(though it will be a bit inefficient.)

Addresses PR#24929.
 1.16  12-Mar-2004  enami Sprinkle cast to prevent unwanted sign extension. Some of those actually
makes sed invoked during build process an out of bound array access.
 1.15  07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22280, verified by myself.
 1.14  22-Jul-2002  christos make this compile with -DREDEBUG again.
 1.13  17-Dec-2001  christos PR/14975: Takayoshi Kochi: memory leak in regexec(3).
Always free m->pmatch and m->lastpos on error.
 1.12  16-Sep-1999  lukem branches: 1.12.10;
* use _DIAGASSERT() to check pointer arguments against NULL and file
descriptors against -1 (as appropriate).
* add actual checks which to detect stuff that would trigger_DIAGASSERT(),
and attempt to return a sane error condition.
* knf some code
* remove some `register' decls.

the first two items result in the addition of code similar to the
following in various functions:

_DIAGASSERT(path != NULL)
#ifdef _DIAGNOSTIC
if (path == NULL) {
errno = EFAULT;
return (-1);
}
#endif
 1.11  20-Jan-1999  christos Avoid overflow when adding a 64 bit quantity to a 32 bit pointer on 32 bit
machines.
 1.10  08-Dec-1998  drochner regoff_t is used like size_t within the code, it should be defined
so instead of off_t. This makes some casts unnecessary.
We can't change the definition now due to binary compatibility, so
prepare for the next libc major version.
 1.9  14-Nov-1998  christos Delint:
- we don't need to use longs; convert to use int32_t.
- remove break statements after returns.
- cast things properly.
 1.8  03-Feb-1998  perry remove obsolete register declarations
 1.7  13-Jul-1997  christos Add missing return NULL;
 1.6  23-Jan-1997  mrg - convert unsafe strcpy(), strcat() and sprintf() to the `n' versions.
- some KNF.
 1.5  27-Feb-1995  cgd add unintrusive Ids
 1.4  30-Jan-1995  cgd clean up import; kill old cruft.
 1.3  23-Feb-1994  jtc Upgrade regex routines to alpha3.3.
 1.2  11-Nov-1993  jtc Update to Henry's Nov 2, 1993 alpha3.2 release.
 1.1  10-Nov-1993  jtc branches: 1.1.1;
Henry Spencer's POSIX.2 compatibile regular expression matching routines.
 1.1.1.1  30-Jan-1995  cgd regex code from lite. same as we're using, but slightly cleaner.
 1.12.10.2  01-Aug-2002  nathanw Catch up to -current.
 1.12.10.1  28-Jan-2002  nathanw Catch up to -current.
 1.21.22.1  13-May-2009  jym Sync with HEAD.

Third (and last) commit. See http://mail-index.netbsd.org/source-changes/2009/05/13/msg221222.html
 1.23.2.1  17-Apr-2012  yamt sync with head

RSS XML Feed