tcopy.c (1fccc1f2ff47eabdee9e06a8efe4019076f21b2a) | tcopy.c (1c8af8787354e20c2b38cab5801698133ff8b403) |
---|---|
1/* 2 * Copyright (c) 1985, 1987, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 67 unchanged lines hidden (view full) --- 76{ 77 register int lastnread, nread, nw, inp, outp; 78 enum {READ, VERIFY, COPY, COPYVERIFY} op = READ; 79 sig_t oldsig; 80 int ch, needeof; 81 char *buff, *inf; 82 83 guesslen = 1; | 1/* 2 * Copyright (c) 1985, 1987, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 67 unchanged lines hidden (view full) --- 76{ 77 register int lastnread, nread, nw, inp, outp; 78 enum {READ, VERIFY, COPY, COPYVERIFY} op = READ; 79 sig_t oldsig; 80 int ch, needeof; 81 char *buff, *inf; 82 83 guesslen = 1; |
84 while ((ch = getopt(argc, argv, "cs:vx")) != EOF) | 84 while ((ch = getopt(argc, argv, "cs:vx")) != -1) |
85 switch((char)ch) { 86 case 'c': 87 op = COPYVERIFY; 88 break; 89 case 's': 90 maxblk = atoi(optarg); 91 if (maxblk <= 0) { 92 fprintf(stderr, "tcopy: illegal block size\n"); --- 240 unchanged lines hidden --- | 85 switch((char)ch) { 86 case 'c': 87 op = COPYVERIFY; 88 break; 89 case 's': 90 maxblk = atoi(optarg); 91 if (maxblk <= 0) { 92 fprintf(stderr, "tcopy: illegal block size\n"); --- 240 unchanged lines hidden --- |