Date: Sun, 25 Jan 2009 23:29:46 GMT From: Gabor Kovesdan <gabor@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 156668 for review Message-ID: <200901252329.n0PNTkl2094494@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=156668 Change 156668 by gabor@gabor_server on 2009/01/25 23:28:52 - Implement --strip-trailing-cr - Remove debug line Affected files ... .. //depot/projects/soc2008/gabor_textproc/diff/diffreg.c#8 edit Differences ... ==== //depot/projects/soc2008/gabor_textproc/diff/diffreg.c#8 (text+ko) ==== @@ -779,15 +779,11 @@ (c == '\n' && d == EOF))) { break; } - if ((strip_cr) && - ((c == EOF && d == '\r') || - (c == '\r' && d == EOF))) - break; ctold++; ctnew++; - while ((strip_cr) && (c == '\r')) + while ((strip_cr) && (c == '\r') && (d == '\n')) c = getc(f1); - while ((strip_cr) && (d == '\r')) + while ((strip_cr) && (d == '\r') && (c == '\n')) d = getc(f2); if (bflag && isspace(c) && isspace(d)) { do { @@ -1288,7 +1284,6 @@ * There is a remote possibility that we end up with a zero sum. * Zero is used as an EOF marker, so return 1 instead. */ - printf("HASH: %d\n", (sum == 0 ? 1 : sum)); return (sum == 0 ? 1 : sum); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901252329.n0PNTkl2094494>