do not get too carried away (from tektronix!sutton <Carl D. Sutton>)
authorKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Tue, 8 Jul 1986 09:38:13 +0000 (01:38 -0800)
committerKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Tue, 8 Jul 1986 09:38:13 +0000 (01:38 -0800)
SCCS-vsn: usr.bin/pascal/libpc/DFDISPOSE.c 4.3

usr/src/usr.bin/pascal/libpc/DFDISPOSE.c

index 4e33705..7a73bd5 100644 (file)
@@ -1,6 +1,6 @@
 /* Copyright (c) 1982 Regents of the University of California */
 
 /* Copyright (c) 1982 Regents of the University of California */
 
-static char sccsid[] = "@(#)DFDISPOSE.c        4.2     (Berkeley)      %G%";
+static char sccsid[] = "@(#)DFDISPOSE.c        4.3     (Berkeley)      %G%";
 
 /*
  * Close all active files within a dynamic record,
 
 /*
  * Close all active files within a dynamic record,
@@ -25,7 +25,7 @@ DFDISPOSE(var, size)
                prev = next;
                next = next->fchain;
        }
                prev = next;
                next = next->fchain;
        }
-       while(next != FILNIL && next < end)
+       while(next != FILNIL && start <= next && next < end)
                next = PFCLOSE(next, TRUE);
        prev->fchain = next;
        DISPOSE(var, size);
                next = PFCLOSE(next, TRUE);
        prev->fchain = next;
        DISPOSE(var, size);