diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2009-05-23 15:14:45 +0200 |
---|---|---|
committer | Tobias Klauser <tklauser@distanz.ch> | 2009-05-23 15:14:45 +0200 |
commit | e016103fa25167594b9ff5d410019f114b7a36fb (patch) | |
tree | 0fd8b5b9c824f3611c24ed00dcbc2058579e15a1 /src/find.c | |
parent | 04b38c4c173cef3b1b12163f1cf5a9b3cef8cb4a (diff) |
New upstream release 15.7a, fixing CVE-2009-014815-7a-1
Diffstat (limited to 'src/find.c')
-rw-r--r-- | src/find.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -48,7 +48,7 @@ #endif #include <regex.h> -static char const rcsid[] = "$Id: find.c,v 1.20 2006/08/20 19:15:54 broeker Exp $"; +static char const rcsid[] = "$Id: find.c,v 1.21 2009/04/10 13:39:23 broeker Exp $"; /* most of these functions have been optimized so their innermost loops have * only one test for the desired character by putting the char and @@ -673,7 +673,7 @@ findinit(char *pattern) /* must be an exact match */ /* note: regcomp doesn't recognize ^*keypad$ as a syntax error unless it is given as a single arg */ - (void) sprintf(buf, "^%s$", s); + (void) snprintf(buf, sizeof(buf), "^%s$", s); if (regcomp (®exp, buf, REG_EXTENDED | REG_NOSUB) != 0) { return(REGCMPERROR); } |