From f875bda849626cb5b894fe56985408ab7ee8f9a3 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Mon, 13 Jan 2014 18:07:29 +0100 Subject: iter: Fix return value in rare memory allocation case --- p11-kit/iter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'p11-kit') diff --git a/p11-kit/iter.c b/p11-kit/iter.c index b6861a5..5301162 100644 --- a/p11-kit/iter.c +++ b/p11-kit/iter.c @@ -860,7 +860,7 @@ p11_kit_iter_load_attributes (P11KitIter *iter, } else { template[i].pValue = realloc (original[i].pValue, template[i].ulValueLen); - return_val_if_fail (template[i].pValue != NULL, 0); + return_val_if_fail (template[i].pValue != NULL, CKR_HOST_MEMORY); } } -- cgit v1.1