Explicit conversions and minor changes to prevent MSVC compiler warnings
diff --git a/library/pkcs5.c b/library/pkcs5.c
index c2aa06d..39aa5b9 100644
--- a/library/pkcs5.c
+++ b/library/pkcs5.c
@@ -269,7 +269,7 @@
         use_len = ( key_length < md_size ) ? key_length : md_size;
         memcpy( out_p, work, use_len );
 
-        key_length -= use_len;
+        key_length -= (uint32_t) use_len;
         out_p += use_len;
 
         for( i = 4; i > 0; i-- )