Lines Matching defs:file1

70 static size_t file1ln, file2ln;	/* line number of file1 and file2 */
119 "usage: sdiff [-abdilstW] [-I regexp] [-o outfile] [-w width] file1 file2\n",
121 "-o OUTFILE, --output=OUTFILE: interactively merge file1 and file2 into outfile.",
126 "\t-a, --text: treat file1 and file2 as text files.",
210 FILE *diffpipe, *file1, *file2;
227 * file1, and file2 won't have arguments so doubling them will
338 * Create temporary files for diff and sdiff to share if file1
346 /* file1 and file2 are the same, so copy to same temp file. */
350 /* Copy file1 and file2 into separate temp files. */
358 if ((file1 = fopen(filename1, "r")) == NULL)
362 if (!istextfile(file1) || !istextfile(file2)) {
363 ret = bindiff(file1, filename1, file2, filename2);
408 while (parsecmd(diffpipe, file1, file2) != EOF)
420 while ((s1 = xfgets(file1)))
424 s1 = xfgets(file1);
431 fclose(file1);
707 * Parse ed commands from diffpipe and print lines from file1 (lines
712 parsecmd(FILE *diffpipe, FILE *file1, FILE *file2)
732 errx(2, "file1 start is %s: %s", errstr, line);
734 /* A range is specified for file1. */
744 errx(2, "file1 end is %s: %s", errstr, line);
746 errx(2, "invalid line range in file1: %s", line);
785 errx(2, "append cannot have a file1 range: %s",
788 errx(2, "file1 line range too high: %s", line);
805 * Continue reading file1 and file2 until we reach line numbers
812 if (!(s1 = xfgets(file1)))
813 errx(2, "file1 shorter than expected");
838 if (!(s = xfgets(file1)))
839 errx(2, "file1 shorter than expected");
866 printc(file1, file1end, file2, file2end);
870 printd(file1, file1end);
1066 printc(FILE *file1, size_t file1end, FILE *file2, size_t file2end)
1080 if (!(line1 = xfgets(file1)))
1081 errx(2, "error reading file1 in delete in change");
1139 printd(FILE *file1, size_t file1end)
1145 if (!(line1 = xfgets(file1)))
1146 errx(2, "file1 ended early in delete");
1175 "usage: sdiff [-abdilstHW] [-I regexp] [-o outfile] [-w width] file1"