Fix iv_len interface.
cipher_info->iv_size == 0 is no longer ambiguous, and
cipher_get_iv_size() always returns something useful to generate an IV.
diff --git a/library/pkcs5.c b/library/pkcs5.c
index 6582fd0..10adbb4 100644
--- a/library/pkcs5.c
+++ b/library/pkcs5.c
@@ -187,7 +187,7 @@
if( ( ret = cipher_setkey( &cipher_ctx, key, keylen, mode ) ) != 0 )
goto exit;
- if( ( ret = cipher_set_iv( &cipher_ctx, iv, 0 ) ) != 0 )
+ if( ( ret = cipher_set_iv( &cipher_ctx, iv, enc_scheme_params.len ) ) != 0 )
goto exit;
if( ( ret = cipher_reset( &cipher_ctx, NULL, 0 ) ) != 0 )