Article View: comp.bugs.sys5
Article #970bug in pr(1) - with fix
From: Mike Wescott
Date: Mon, 06 Feb 1989 18:57
Date: Mon, 06 Feb 1989 18:57
26 lines
1328 bytes
1328 bytes
If pr is used with an odd page length and double space
is specified, only the first page will get printed.
Fix:
*** /tmp/pr.c.orig Mon Feb 6 10:44:14 1989
--- /tmp/pr.c Mon Feb 6 10:46:06 1989
***************
*** 376,382 ****
p->c_ptr0 = p->c_ptr = s;
if (p == &Colpts[Ncols]) return;
(p++)->c_lno = Lnumb + bline;
! for (j = (Length - Margin)/Dblspace; --j >= 0; ++bline)
for (Inpos = 0; ; ) {
if ((c = getc(Files->f_f)) == EOF) {
for (*s = EOF; p <= &Colpts[Ncols]; ++p)
--- 376,382 ----
p->c_ptr0 = p->c_ptr = s;
if (p == &Colpts[Ncols]) return;
(p++)->c_lno = Lnumb + bline;
! for (j = (Length - Margin + Dblspace - 1)/Dblspace; --j >= 0; ++bline)
for (Inpos = 0; ; ) {
if ((c = getc(Files->f_f)) == EOF) {
for (*s = EOF; p <= &Colpts[Ncols]; ++p)
--
-Mike Wescott
mike.wescott@ncrcae.Columbia.NCR.COM
Technical Details
Message-ID:
<1534@sauron.Columbia.NCR.COM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cwjcc!gatech!hubcap!ncrcae!sauron!wescottShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cwjcc!gatech!hubcap!ncrcae!sauron!wescott From: wescott@sauron.Columbia.NCR.COM (Mike Wescott) Newsgroups: comp.bugs.sys5 Subject: bug in pr(1) - with fix Message-ID: <1534@sauron.Columbia.NCR.COM> Date: 6 Feb 89 18:57:53 GMT Reply-To: wescott@sauron.Columbia.NCR.COM (Mike Wescott) Organization: Entry Level Systems Development, NCR Corp., Columbia, SC Lines: 26