From 32be9184bcab815ed1795889612a2c2c84a17334 Mon Sep 17 00:00:00 2001
From: wangzhengquan <wangzhengquan85@126.com>
Date: 星期二, 13 十月 2020 19:24:28 +0800
Subject: [PATCH] Merge branch 'master' into dev
---
test/test.c | 17 +++++++++--------
1 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/test/test.c b/test/test.c
index 744ac72..dcb5d74 100644
--- a/test/test.c
+++ b/test/test.c
@@ -1,12 +1,13 @@
#include "usg_common.h"
-#include "usg_typedef.h"
-
-void test(char *src, int size) {
- char dest[size];
- strncpy(dest, src, size);
- puts(dest);
+
+int test() {
+ static int count = 0;
+ count++;
+ return count;
}
int main() {
- char *str = "hello";
- test(str, strlen(str));
+
+
+ printf("%d\n", test());
+ printf("%d\n", test());
}
\ No newline at end of file
--
Gitblit v1.8.0