diff options
author | Richard Levitte <levitte@openssl.org> | 2002-05-30 16:49:00 +0000 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2002-05-30 16:49:00 +0000 |
commit | d66c022a1f6835e73bccf9a8b11869cbe20814a7 (patch) | |
tree | 28105b668a3fba5fe07014a8610f986c86aa1bcd /crypto/txt_db | |
parent | 04c8e99b39413d9bb8962f6d8240f389e66b0739 (diff) |
Check the return values where memory allocation failures may happen.
PR: 49
Diffstat (limited to 'crypto/txt_db')
-rw-r--r-- | crypto/txt_db/txt_db.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/txt_db/txt_db.c b/crypto/txt_db/txt_db.c index 3b04fe280c..92fcbde47f 100644 --- a/crypto/txt_db/txt_db.c +++ b/crypto/txt_db/txt_db.c @@ -122,7 +122,7 @@ TXT_DB *TXT_DB_read(BIO *in, int num) else { buf->data[offset-1]='\0'; /* blat the '\n' */ - p=(char *)OPENSSL_malloc(add+offset); + if (!(p=(char *)OPENSSL_malloc(add+offset))) goto err; offset=0; } pp=(char **)p; |