Mercurial > hg > Members > kono > tree_dandy2
annotate debug.c @ 21:b7654db65a34
add TODO
author | koba <koba@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Fri, 10 Dec 2010 19:04:17 +0900 |
parents | 972a7f233b23 |
children |
rev | line source |
---|---|
0 | 1 #include <stdlib.h> |
2 #include <stdio.h> | |
3 #include <stdarg.h> | |
4 #include "count2.h" | |
5 | |
6 static FILE *dbg_fp; | |
7 | |
7 | 8 void dbg_init(const char *fname) |
0 | 9 { |
10 dbg_fp = fopen(fname, "w"); | |
11 } | |
12 | |
7 | 13 int dbg_printf(const char *format, ...) |
0 | 14 { |
15 va_list ap; | |
16 va_start(ap, format); | |
17 vfprintf(dbg_fp, format, ap); | |
18 va_end(ap); | |
19 // fflush(dbg_fp); | |
20 return (0); | |
21 } |