summaryrefslogtreecommitdiff
path: root/tests/test_strcat_static_write.c
diff options
context:
space:
mode:
authorjvoisin2023-04-13 23:44:52 +0200
committerjvoisin2023-04-13 23:49:02 +0200
commitfa40365faea6b87288504f0d8ad39dab8ff302b4 (patch)
tree378ad91e5bedb268e2ecc15e668830189dfe32b0 /tests/test_strcat_static_write.c
parent56d760c5cb1c07dfa409742d51f836792a09d824 (diff)
Add tests for strcat and strcpy
Diffstat (limited to 'tests/test_strcat_static_write.c')
-rw-r--r--tests/test_strcat_static_write.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/test_strcat_static_write.c b/tests/test_strcat_static_write.c
new file mode 100644
index 0000000..d0cb903
--- /dev/null
+++ b/tests/test_strcat_static_write.c
@@ -0,0 +1,16 @@
1#include "common.h"
2
3#include <string.h>
4
5int main(int argc, char** argv) {
6 char buffer[8] = {0};
7 strcat(buffer, "1234567");
8 puts(buffer);
9
10 CHK_FAIL_START
11 strcat(buffer, "1234567890");
12 CHK_FAIL_END
13
14 puts(buffer);
15 return ret;
16}