diff options
author | Jim Meyering <meyering@redhat.com> | 2010-12-27 18:19:56 -0500 |
---|---|---|
committer | Ulrich Drepper <drepper@gmail.com> | 2010-12-27 18:19:56 -0500 |
commit | 2543fef229599e8a6e4feeea65ca2dd3f984154f (patch) | |
tree | ac2ed911516c1c54273899a23af4fd6b2e941b8f /posix | |
parent | db014c12695388b4e6eb608a4132a8c7b4ee74f1 (diff) | |
download | glibc-2543fef229599e8a6e4feeea65ca2dd3f984154f.tar.gz glibc-2543fef229599e8a6e4feeea65ca2dd3f984154f.tar.xz glibc-2543fef229599e8a6e4feeea65ca2dd3f984154f.zip |
Fix infloop on persistent failing calloc in regex.
Diffstat (limited to 'posix')
-rw-r--r-- | posix/regexec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/posix/regexec.c b/posix/regexec.c index 7f7ae3123f..8d4475cdb9 100644 --- a/posix/regexec.c +++ b/posix/regexec.c @@ -3373,6 +3373,8 @@ build_trtable (const re_dfa_t *dfa, re_dfastate_t *state) { state->trtable = (re_dfastate_t **) calloc (sizeof (re_dfastate_t *), SBC_MAX); + if (BE (state->trtable == NULL, 0)) + return 0; return 1; } return 0; |