stdio.h defines BUFSIZ
[unix-history] / usr / src / usr.bin / more / position.c
index ddb7fdb..ac60fe1 100644 (file)
@@ -3,22 +3,11 @@
  * Copyright (c) 1988 Regents of the University of California.
  * All rights reserved.
  *
  * Copyright (c) 1988 Regents of the University of California.
  * All rights reserved.
  *
- * Redistribution and use in source and binary forms are permitted
- * provided that the above copyright notice and this paragraph are
- * duplicated in all such forms and that any documentation,
- * advertising materials, and other materials related to such
- * distribution and use acknowledge that the software was developed
- * by Mark Nudleman and the University of California, Berkeley.  The
- * name of Mark Nudleman or the
- * University may not be used to endorse or promote products derived
- * from this software without specific prior written permission.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
- * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ * %sccs.include.redist.c%
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)position.c 5.5 (Berkeley) %G%";
+static char sccsid[] = "@(#)position.c 5.7 (Berkeley) %G%";
 #endif /* not lint */
 
 /*
 #endif /* not lint */
 
 /*
@@ -119,10 +108,10 @@ pos_clear()
 
        if (table == 0) {
                tablesize = sc_height > 25 ? sc_height : 25;
 
        if (table == 0) {
                tablesize = sc_height > 25 ? sc_height : 25;
-               table = malloc(tablesize * sizeof *table);
+               table = (off_t *)malloc(tablesize * sizeof *table);
        } else if (sc_height >= tablesize) {
                tablesize = sc_height;
        } else if (sc_height >= tablesize) {
                tablesize = sc_height;
-               table = realloc(table, tablesize * sizeof *table);
+               table = (off_t *)realloc(table, tablesize * sizeof *table);
        }
 
        for (i = 0;  i < sc_height;  i++)
        }
 
        for (i = 0;  i < sc_height;  i++)