diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ref15.txt | 1 | ||||
| -rwxr-xr-x | tests/test15 | bin | 0 -> 19664 bytes | |||
| -rw-r--r-- | tests/test15.c | 24 |
3 files changed, 25 insertions, 0 deletions
diff --git a/tests/ref15.txt b/tests/ref15.txt new file mode 100644 index 00000000..b2bb8503 --- /dev/null +++ b/tests/ref15.txt @@ -0,0 +1 @@ +Hello x86_64 World, pi=3.14159! diff --git a/tests/test15 b/tests/test15 new file mode 100755 index 00000000..b2bd8836 --- /dev/null +++ b/tests/test15 Binary files differdiff --git a/tests/test15.c b/tests/test15.c new file mode 100644 index 00000000..b00c7171 --- /dev/null +++ b/tests/test15.c @@ -0,0 +1,24 @@ +#include <stdio.h> +#include <stdarg.h> + +int my_func(const char* fmt, va_list a) +{ + return vprintf(fmt, a); +} + +int my_func1(const char* fmt, ...) +{ + va_list args; + va_start(args, fmt); + int ret = my_func(fmt, args); + va_end(args); + return ret; +} + +int main(int argc, char **argv) +{ + int ret = my_func1("Hello %s World, pi=%g!\n", "x86_64", 3.14159265); + return 0; +} + + |