static FILE *Tinputfile, *Tfuzzrawfile, *Treportfile;
static vbuf vb2;
-static void Tensurereportfile(void) {
+static void Tensure_reportfile(void) {
const char *fdstr;
int fd;
Treportfile= fdopen(fd,"a"); if (!Treportfile) Tfailed("fdopen ADNS_TEST_REPORT_FD");
}
-static void Tensurefuzzrawfile(void) {
+static void Tensure_fuzzrawfile(void) {
static int done;
if (done) return;
int chars;
unsigned long sec, usec;
+ Tensure_reportfile();
+ Tensure_fuzzrawfile();
+
if (Tinputfile) return;
Tinputfile= stdin;
fd = Ttestinputfd();
vb.used,vb.buf, vb.used,vb2.buf+1);
exit(1);
}
- Tensurereportfile();
nl= memchr(vb.buf,'\n',vb.used);
fprintf(Treportfile," %.*s\n", (int)(nl ? nl - (const char*)vb.buf : vb.used), vb.buf);
}
if (!adns__vbuf_ensure(&vb2,1000)) Tnomem();
fgets(vb2.buf,vb2.avail,Tinputfile); Pcheckinput();
- Tensurereportfile();
- Tensurefuzzrawfile();
+ Tensuresetup();
fprintf(Treportfile,"%s",vb2.buf);
amtread= strlen(vb2.buf);
if (amtread<=0 || vb2.buf[--amtread]!=hm_squote\nhm_squote)