Deleted Added
full compact
read.c (17339) read.c (17341)
1/*-
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Edward Sze-Tyan Wang.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 99 unchanged lines hidden (view full) ---

108 WR(sp, tlen);
109 }
110 } else {
111 if (wrap && (len = ep - p))
112 WR(p, len);
113 if (len = p - sp)
114 WR(sp, len);
115 }
1/*-
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Edward Sze-Tyan Wang.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 99 unchanged lines hidden (view full) ---

108 WR(sp, tlen);
109 }
110 } else {
111 if (wrap && (len = ep - p))
112 WR(p, len);
113 if (len = p - sp)
114 WR(sp, len);
115 }
116 return 0;
116}
117
118/*
119 * lines -- read lines to an offset from the end and display.
120 *
121 * This is the function that reads to a line offset from the end of the input,
122 * storing the data in an array of buffers which is then displayed. If the
123 * rflag is set, the data is displayed in lines in reverse order, and this

--- 66 unchanged lines hidden (view full) ---

190 WR(lines[cnt].l, lines[cnt].len);
191 } else {
192 if (wrap)
193 for (cnt = recno; cnt < off; ++cnt)
194 WR(lines[cnt].l, lines[cnt].len);
195 for (cnt = 0; cnt < recno; ++cnt)
196 WR(lines[cnt].l, lines[cnt].len);
197 }
117}
118
119/*
120 * lines -- read lines to an offset from the end and display.
121 *
122 * This is the function that reads to a line offset from the end of the input,
123 * storing the data in an array of buffers which is then displayed. If the
124 * rflag is set, the data is displayed in lines in reverse order, and this

--- 66 unchanged lines hidden (view full) ---

191 WR(lines[cnt].l, lines[cnt].len);
192 } else {
193 if (wrap)
194 for (cnt = recno; cnt < off; ++cnt)
195 WR(lines[cnt].l, lines[cnt].len);
196 for (cnt = 0; cnt < recno; ++cnt)
197 WR(lines[cnt].l, lines[cnt].len);
198 }
199 return 0;
198}
200}