Loading src/main.c +15 −1 Original line number Diff line number Diff line Loading @@ -654,6 +654,20 @@ static int getparameter(char *flag, /* f or -long-flag */ return URG_FAILED_INIT; case 'w': /* get the output string */ if('@' == *nextarg) { /* the data begins with a '@' letter, it means that a file name or - (stdin) follows */ FILE *file; nextarg++; /* pass the @ */ if(strequal("-", nextarg)) file = stdin; else file = fopen(nextarg, "r"); config->writeout = file2string(file); if(file && (file != stdin)) fclose(stdin); } else GetStr(&config->writeout, nextarg); break; case 'x': Loading Loading
src/main.c +15 −1 Original line number Diff line number Diff line Loading @@ -654,6 +654,20 @@ static int getparameter(char *flag, /* f or -long-flag */ return URG_FAILED_INIT; case 'w': /* get the output string */ if('@' == *nextarg) { /* the data begins with a '@' letter, it means that a file name or - (stdin) follows */ FILE *file; nextarg++; /* pass the @ */ if(strequal("-", nextarg)) file = stdin; else file = fopen(nextarg, "r"); config->writeout = file2string(file); if(file && (file != stdin)) fclose(stdin); } else GetStr(&config->writeout, nextarg); break; case 'x': Loading