mirror of
https://codeberg.org/scip/pcp.git
synced 2025-12-17 12:00:56 +01:00
fix (null) output if input for -C is stdin
This commit is contained in:
@@ -366,8 +366,10 @@ void pcpchecksum(char **files, int filenum) {
|
|||||||
|
|
||||||
for(i=0; i<filenum; i++) {
|
for(i=0; i<filenum; i++) {
|
||||||
FILE *in;
|
FILE *in;
|
||||||
if(files[i] == NULL)
|
if(files[i] == NULL) {
|
||||||
in = stdin;
|
in = stdin;
|
||||||
|
files[i] = "stdin";
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
if((in = fopen(files[i], "rb")) == NULL) {
|
if((in = fopen(files[i], "rb")) == NULL) {
|
||||||
fatal(ptx, "Could not open input file %s\n", files[i]);
|
fatal(ptx, "Could not open input file %s\n", files[i]);
|
||||||
|
|||||||
Reference in New Issue
Block a user