Thread View: net.bugs.4bsd
2 messages
2 total messages
Started by Steve Grandi
Thu, 16 Oct 1986 01:36
troff/nroff/ditroff end-macro bug
Author: Steve Grandi
Date: Thu, 16 Oct 1986 01:36
Date: Thu, 16 Oct 1986 01:36
67 lines
2355 bytes
2355 bytes
Subject: troff/nroff prematurely interrupts end-macro processing
Index: /usr/src/usr.bin/troff/n7.c 4.3BSD
Description:
(The following bug-report and fix are from D'Anne Thompson)
End-macro processing in troff/nroff/ditroff is being prematurely
interrupted. Only a single page of text was being ejected upon reaching the
end of input text. This was the case even when there was diverted material,
notably a floating keep, that should be floated to the top of another new
page. After investigation it was found that only the current page at the
time of reaching the end-macro was being completed, any additional pages that
might be due to the end-macro processing itself were being suppressed.
Repeat-By:
Run the following through troff/nroff using -me
.fo ''Footer''
.pp
A normal paragraph.
A normal paragraph.
A normal paragraph.
A normal paragraph.
A normal paragraph.
A normal paragraph.
A normal paragraph.
A normal paragraph.
.sp 7.0i
.(z
A Floating keep.
It should float to the top of the
following page.
This should be the second page output, if end-macro
processing is working correctly.
She sells sea shells by the sea shore.
.)z
.pp
A normal paragraph.
Fix:
file n7.c, subroutine newline()
*** n7.c.ORIG Thu Aug 5 14:53:14 1982
--- n7.c Tue Sep 16 16:01:51 1986
***************
*** 423,429 ****
nl1:
ejf = dip->hnl = v.nl = 0;
ejl = frame;
! if(donef){
if((!nc && !wch) || ndone)done1(0);
ndone++;
donef = 0;
--- 423,429 ----
nl1:
ejf = dip->hnl = v.nl = 0;
ejl = frame;
! if(donef == 1){
if((!nc && !wch) || ndone)done1(0);
ndone++;
donef = 0;
--
Steve Grandi, National Optical Astronomy Observatories, Tucson, AZ, 602-325-9228
{arizona,decvax,hao,ihnp4,seismo}!noao!grandi grandi%draco@Hamlet.Caltech.Edu
Re: troff/nroff/ditroff end-macro bug
Author: edmoy
Date: Thu, 16 Oct 1986 16:50
Date: Thu, 16 Oct 1986 16:50
16 lines
1173 bytes
1173 bytes
Steve & D'Anne, It's amazing that it seems that you and I have uncovered and fixed this bug at about the same time. Myself, I wasn't sure of any possible side- effects this might cause, as even though I've been hacking with troff the last almost three years, I'm still much afraid of fixing something and breaking something else. It's comforting to know that someone else has come up independently with the same solution. Thanks. Edward Moy Academic Computing Services University of California Berkeley, CA 94720 edmoy@ucbopal.Berkeley.EDU ucbvax!opal!edmoy
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads