summaryrefslogblamecommitdiffstats
path: root/test/fopen_mkdir-test.c
blob: 9a2acfc9f55b17b8e69aa43d7bc59f94a0f253de (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14













                                                                             
#include <stdlib.h>
#include <stdio.h>
#include "fopenmkdir.c"

extern int main(int argc, char* argv[]) {
	if(argc != 3) {
		printf("usage: %s file_to_write string_to_write\n", argv[0]);
		return 1;
	}
	FILE * test_file;
	test_file = fopen_mkdir(argv[1], "w");
	fprintf(test_file, "%s\n", argv[2]);
	return 0;
}