Replaced strcpy() with strncpy() in tests suites
diff --git a/tests/suites/test_suite_mdx.function b/tests/suites/test_suite_mdx.function
index 0676d82..24fb328 100644
--- a/tests/suites/test_suite_mdx.function
+++ b/tests/suites/test_suite_mdx.function
@@ -16,7 +16,7 @@
memset( hash_str, 0x00, sizeof hash_str );
memset( output, 0x00, sizeof output );
- strcpy( (char *) src_str, text_src_string );
+ strncpy( (char *) src_str, text_src_string, sizeof(src_str) - 1 );
md2( src_str, strlen( (char *) src_str ), output );
hexify( hash_str, output, sizeof output );
@@ -36,7 +36,7 @@
memset( hash_str, 0x00, sizeof hash_str );
memset( output, 0x00, sizeof output );
- strcpy( (char *) src_str, text_src_string );
+ strncpy( (char *) src_str, text_src_string, sizeof(src_str) - 1 );
md4( src_str, strlen( (char *) src_str ), output );
hexify( hash_str, output, sizeof output );
@@ -56,7 +56,7 @@
memset( hash_str, 0x00, sizeof hash_str );
memset( output, 0x00, sizeof output );
- strcpy( (char *) src_str, text_src_string );
+ strncpy( (char *) src_str, text_src_string, sizeof(src_str) - 1 );
md5( src_str, strlen( (char *) src_str ), output );
hexify( hash_str, output, sizeof output );
@@ -76,7 +76,7 @@
memset(hash_str, 0x00, sizeof hash_str);
memset(output, 0x00, sizeof output);
- strcpy( (char *) src_str, text_src_string );
+ strncpy( (char *) src_str, text_src_string, sizeof(src_str) - 1 );
ripemd160( src_str, strlen( (char *) src_str ), output );
hexify( hash_str, output, sizeof output );