|
|
1.1 ! root 1: /* @(#)diff.h 4.1 10/9/80" */ ! 2: ! 3: /* ! 4: * diff - common declarations ! 5: */ ! 6: ! 7: #include <stdio.h> ! 8: #include <ctype.h> ! 9: #include <sys/types.h> ! 10: #include <sys/stat.h> ! 11: #include <signal.h> ! 12: #include <sys/dir.h> ! 13: ! 14: /* ! 15: * Output format options ! 16: */ ! 17: int opt; ! 18: ! 19: #define D_NORMAL 0 /* Normal output */ ! 20: #define D_EDIT -1 /* Editor script out */ ! 21: #define D_REVERSE 1 /* Reverse editor script */ ! 22: #define D_CONTEXT 2 /* Diff with context */ ! 23: ! 24: /* ! 25: * Algorithm related options ! 26: */ ! 27: int hflag; /* -h, use halfhearted DIFFH */ ! 28: int bflag; /* 1 = ignore quantity of white space ! 29: 2 = ignore white space entirely */ ! 30: ! 31: /* ! 32: * Options on hierarchical diffs. ! 33: */ ! 34: int rflag; /* recursively trace directories */ ! 35: int sflag; /* announce files which are same */ ! 36: ! 37: /* ! 38: * Variables for -c context option. ! 39: */ ! 40: int context; /* lines of context to be printed */ ! 41: ! 42: /* ! 43: * State for exit status. ! 44: */ ! 45: int status; ! 46: int anychange; ! 47: char tempfile[2][16]; /* used when comparing against char special ! 48: devices or standard input */ ! 49: int whichtemp; ! 50: ! 51: /* ! 52: * Variables for diffdir. ! 53: */ ! 54: char **diffargv; /* option list to pass to recursive diffs */ ! 55: ! 56: /* ! 57: * Input file names. ! 58: * With diffdir, file1 and file2 are allocated BUFSIZ space, ! 59: * and padded with a '/', and then efile0 and efile1 point after ! 60: * the '/'. ! 61: */ ! 62: char *file1, *file2, *efile1, *efile2; ! 63: struct stat stb1, stb2; ! 64: struct stat stb1, stb2; ! 65: ! 66: /* ! 67: * This is allocated early, and used ! 68: * to reset the free storage pointer to effect space compaction. ! 69: */ ! 70: char *dummy; ! 71: ! 72: char *malloc(), *realloc(), *talloc(), *ralloc(); ! 73: char *savestr(), *splice(), *splicen(); ! 74: char *mktemp(), *copytemp(), *strrchr(); ! 75: int done(); ! 76: ! 77: extern char diffh[], diff[], pr[];
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.