]> code.delx.au - gnu-emacs/blobdiff - src/unexhp9k800.c
(syms_of_lread) <load-history>: Doc fix.
[gnu-emacs] / src / unexhp9k800.c
index 76bfa1f855151af45a083be6d53fbd7e807ac0fe..686a1ed1ebb4058596cfc16dffbe76b593f76f7a 100644 (file)
   sigsetreturn (_sigreturn);
 */
 \f
+#ifdef emacs
+#include <config.h>
+#endif
+
 #include <stdio.h>
 #include <fcntl.h>
 #include <errno.h>
 
 #include <a.out.h>
 
-#ifdef emacs
-#include <config.h>
-#endif
-
 #ifdef HPUX_USE_SHLIBS
 #include <dl.h>
 #endif
@@ -60,9 +60,10 @@ int
 run_time_remap (ignored)
      char *ignored;
 {
-  brk (brk_on_dump);
+  brk ((char *) brk_on_dump);
 }
 
+#undef roundup
 #define roundup(x,n) (((x) + ((n) - 1)) & ~((n) - 1))  /* n is power of 2 */
 #define min(x,y)  (((x) < (y)) ? (x) : (y))
 
@@ -99,13 +100,13 @@ unexec (new_name, old_name, new_end_of_text, dummy1, dummy2)
   /* Read the old headers */
   read_header (old, &hdr, &auxhdr);
 
-  brk_on_dump = sbrk (0);
+  brk_on_dump = (long) sbrk (0);
   
   /* Decide how large the new and old data areas are */
   old_size = auxhdr.exec_dsize;
   /* I suspect these two statements are separate
      to avoid a compiler bug in hpux version 8.  */
-  i = sbrk (0);
+  i = (long) sbrk (0);
   new_size = i - auxhdr.exec_dmem;
   
   /* Copy the old file to the new, up to the data space */