tccpp.c: Guard against ppfp being NULL

Missed these in e946eb2a41
This commit is contained in:
Vlad Vissoultchev
2016-04-13 10:48:15 +03:00
parent 6a49afb3ed
commit 810a677d32
2 changed files with 18 additions and 24 deletions

9
tcc.c
View File

@ -303,13 +303,8 @@ int main(int argc, char **argv)
tcc_error("could not write '%s'", s->outfile);
}
s->dffp = s->ppfp;
if (s->dflag == 'M') {
#ifndef TCC_TARGET_PE
s->ppfp = fopen("/dev/null", "w");
#else
s->ppfp = fopen("nul", "w");
#endif
}
if (s->dflag == 'M')
s->ppfp = NULL;
}
tcc_set_output_type(s, s->output_type);