void rop2(void) { size_t first, last, a; deletenone(); clrstats(); first = addr2 - fendcore + 1; bsize = LBSIZE; /* Don't remove! -CK- */ ignore(append(getfile, addr2)); last = dot - fendcore; /* * if the modeline variable is set, * check the first and last five lines of the file * for a mode line. */ if (value(MODELINE)) { for (a=first; a<=last; a++) { if (a==first+5 && last-first > 10) a = last - 4; ex_getline(*(fendcore + a)); checkmodeline(linebuf); } } }
void rop2(void) { deletenone(); clrstats(); ignore(append(getfile, addr2)); }
/* ARGSUSED */ void putfile(int isfilter) { line *a1; register char *fp, *lp; register int nib; #ifndef CRYPT (void)isfilter; #endif a1 = addr1; clrstats(); cntln = addr2 - a1 + 1; if (cntln == 0) return; bsize = LBSIZE; nib = bsize; fp = genbuf; do { ex_getline(*a1++); lp = linebuf; for (;;) { if (--nib < 0) { nib = fp - genbuf; #ifdef CRYPT if(kflag && !isfilter) crblock(perm, genbuf, nib, cntch); #endif if (write(io, genbuf, nib) != nib) { wrerror(); } cntch += nib; nib = bsize - 1; fp = genbuf; } if ((*fp++ = *lp++) == 0) { fp[-1] = '\n'; break; } } } while (a1 <= addr2); nib = fp - genbuf; #ifdef CRYPT if(kflag && !isfilter) crblock(perm, genbuf, nib, cntch); #endif if (write(io, genbuf, nib) != nib) { wrerror(); } cntch += nib; }
void rop2(void) { line *first, *last, *a; deletenone(); clrstats(); first = addr2 + 1; (void)append(getfile, addr2); last = dot; if (value(vi_MODELINES)) for (a=first; a<=last; a++) { if (a==first+5 && last-first > 10) a = last - 4; getaline(*a); chkmdln(linebuf); } }