Skip to content

Commit 3f7cb19

Browse files
committed
add uintptr_t cast in Md5 mallocNativeStruct
1 parent 675fdb2 commit 3f7cb19

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

jni/jni_md5.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
2020
*/
2121

22+
#include <stdint.h>
2223
#ifndef __ANDROID__
2324
#include <wolfssl/options.h>
2425
#endif
@@ -50,7 +51,7 @@ Java_com_wolfssl_wolfcrypt_Md5_mallocNativeStruct(
5051
jlong ret = 0;
5152

5253
#ifndef NO_MD5
53-
ret = (jlong) XMALLOC(sizeof(Md5), NULL, DYNAMIC_TYPE_TMP_BUFFER);
54+
ret = (jlong)(uintptr_t)XMALLOC(sizeof(Md5), NULL, DYNAMIC_TYPE_TMP_BUFFER);
5455

5556
if (!ret)
5657
throwOutOfMemoryException(env, "Failed to allocate Md5 object");

0 commit comments

Comments
 (0)