~darklands/md2roff

c68c4317f9159bf2890640cc05afbd38a2cc1398 — Ben O'Neill 1 year, 3 months ago 50d345f
Fix arguments with stdin
1 files changed, 5 insertions(+), 2 deletions(-)

M md2roff.l
M md2roff.l => md2roff.l +5 -2
@@ 92,7 92,11 @@ int main(int argc, char *argv[])
			}
		}
		printf(".fp 8 C\n");
		yyin = fopen(file, "r");
		if (file == NULL) {
			yyin = stdin;
		} else {
			yyin = fopen(file, "r");
		}
		if (!yyin) {
			fprintf(stderr, "error: can't open input file\n");
			exit(EXIT_FAILURE);


@@ 100,7 104,6 @@ int main(int argc, char *argv[])
		yylex();
	} else {
		printf(".fp 8 C\n");
		yyin = fopen(file, "r");
		yyin = stdin;
		yylex();
	}