From 964373b25d3dc015951fb00d9c8c68632890a55e Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 13 Mar 2006 05:00:45 +0000 Subject: r14293: fixed some errors found with beam (This used to be commit 230636a00ed9bd968356badad596ba7f93ba6c85) --- source4/dsdb/samdb/ldb_modules/password_hash.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source4/dsdb/samdb/ldb_modules') diff --git a/source4/dsdb/samdb/ldb_modules/password_hash.c b/source4/dsdb/samdb/ldb_modules/password_hash.c index 2abf060a0f..6980fe48b8 100644 --- a/source4/dsdb/samdb/ldb_modules/password_hash.c +++ b/source4/dsdb/samdb/ldb_modules/password_hash.c @@ -496,6 +496,9 @@ static int password_hash_handle(struct ldb_module *module, struct ldb_request *r continue; } ASN1_MALLOC_ENCODE(Key, buf, buf_size, &keys[i], &len, krb5_ret); + if (krb5_ret) { + return LDB_ERR_OPERATIONS_ERROR; + } val.data = talloc_memdup(req, buf, len); val.length = len; @@ -549,6 +552,9 @@ static int password_hash_handle(struct ldb_module *module, struct ldb_request *r return LDB_ERR_OPERATIONS_ERROR; } ASN1_MALLOC_ENCODE(Key, buf, buf_size, &key, &len, krb5_ret); + if (krb5_ret) { + return LDB_ERR_OPERATIONS_ERROR; + } krb5_free_keyblock_contents(smb_krb5_context->krb5_context, &key.key); -- cgit