mirror of git://git.sv.gnu.org/nano.git
add comment
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2455 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
This commit is contained in:
parent
4857728f6e
commit
00762ffaeb
|
@ -36,11 +36,13 @@
|
|||
|
||||
#ifdef HAVE_REGEX_H
|
||||
#ifdef BROKEN_REGEXEC
|
||||
/* Work around a potential segfault in glibc 2.2.3's regexec(). */
|
||||
int safe_regexec(const regex_t *preg, const char *string, size_t nmatch,
|
||||
regmatch_t pmatch[], int eflags)
|
||||
{
|
||||
if (string != NULL && *string != '\0')
|
||||
return regexec(preg, string, nmatch, pmatch, eflags);
|
||||
|
||||
return REG_NOMATCH;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue