Skip to content
Snippets Groups Projects
Commit a09fed84 authored by rtoy's avatar rtoy
Browse files

Fix more compiler warnings:

* alloc.c, coreparse.c, monitor.c, validate.c, vars.c:  #include some
  files to get declarations of functions.

* coreparse.c, lisp.c, monitor.c: Fix printf warnings about args not
  matching the format string.
parent 8b89d264
No related branches found
No related tags found
No related merge requests found
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/alloc.c,v 1.7 2004/07/07 20:31:06 rtoy Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/alloc.c,v 1.8 2004/07/08 17:49:04 rtoy Exp $ */
#include <string.h>
#include "lisp.h"
#include "internals.h"
......
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/coreparse.c,v 1.8 2004/07/08 03:37:53 rtoy Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/coreparse.c,v 1.9 2004/07/08 17:49:04 rtoy Exp $ */
#include <stdio.h>
#include <sys/types.h>
#include <sys/file.h>
#ifdef irix
#if defined(irix) || defined(sparc)
#include <fcntl.h>
#include <stdlib.h>
#endif
......@@ -40,9 +40,9 @@ static void process_directory(int fd, long *ptr, int count)
real_addr=os_map(fd, offset, addr, len);
if(real_addr!=addr)
fprintf(stderr,
"process_directory: file mapped in wrong place! (0x%p != 0x%p)\n",
real_addr,
addr);
"process_directory: file mapped in wrong place! (0x%p != 0x%p)\n",
(void *) real_addr,
(void *) addr);
}
#if 0
......
/*
* main() entry point for a stand alone lisp image.
*
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/lisp.c,v 1.41 2004/07/07 15:03:12 rtoy Exp $
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/lisp.c,v 1.42 2004/07/08 17:49:04 rtoy Exp $
*
*/
......@@ -54,7 +54,7 @@ static void sigint_handler(HANDLER_ARGS)
SAVE_CONTEXT();
printf("\nSIGINT hit at 0x%08lX\n", SC_PC(context));
printf("\nSIGINT hit at 0x%08lX\n", (unsigned long) SC_PC(context));
ldb_monitor();
}
......
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/monitor.c,v 1.16 2004/07/08 04:10:09 rtoy Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/monitor.c,v 1.17 2004/07/08 17:49:04 rtoy Exp $ */
#include <stdio.h>
#include <sys/types.h>
......@@ -7,6 +7,7 @@
#include <sys/time.h>
#include <sys/resource.h>
#include <signal.h>
#include <string.h>
#include "lisp.h"
#include "internals.h"
......@@ -141,7 +142,7 @@ static void regs_cmd(char **ptr)
printf("CSP\t=\t0x%08lX\n", (unsigned long)current_control_stack_pointer);
printf("FP\t=\t0x%08lX\n", (unsigned long)current_control_frame_pointer);
#if !defined(ibmrt) && !defined(i386) && !defined(__x86_64)
printf("BSP\t=\t0x%08X\n", (unsigned long)current_binding_stack_pointer);
printf("BSP\t=\t0x%08lX\n", (unsigned long)current_binding_stack_pointer);
#endif
#if defined(i386) || defined(__x86_64)
printf("BSP\t=\t0x%08lX\n", SymbolValue(BINDING_STACK_POINTER));
......@@ -152,9 +153,8 @@ static void regs_cmd(char **ptr)
printf("ALLOC\t=\t0x%08lX\n", SymbolValue(ALLOCATION_POINTER));
printf("TRIGGER\t=\t0x%08lX\n", SymbolValue(INTERNAL_GC_TRIGGER));
#else
printf("ALLOC\t=\t0x%08X\n",
(unsigned long)current_dynamic_space_free_pointer);
printf("TRIGGER\t=\t0x%08X\n", (unsigned long)current_auto_gc_trigger);
printf("ALLOC\t=\t0x%08lX\n", (unsigned long) current_dynamic_space_free_pointer);
printf("TRIGGER\t=\t0x%08lX\n", (unsigned long)current_auto_gc_trigger);
#endif
printf("STATIC\t=\t0x%08lX\n", SymbolValue(STATIC_SPACE_FREE_POINTER));
printf("RDONLY\t=\t0x%08lX\n", SymbolValue(READ_ONLY_SPACE_FREE_POINTER));
......@@ -345,7 +345,7 @@ static void print_context(os_context_t *context)
brief_print((lispobj) SC_REG(context, i));
#endif
}
printf("PC:\t\t 0x%08lx\n", SC_PC(context));
printf("PC:\t\t 0x%08lx\n", (unsigned long) SC_PC(context));
}
static void print_context_cmd(char **ptr)
......
/*
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/validate.c,v 1.18 2004/05/19 23:38:13 cwang Exp $
* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/validate.c,v 1.19 2004/07/08 17:49:04 rtoy Exp $
*
* Memory Validation
*/
#include <stdio.h>
#include <unistd.h>
#ifdef __SUNPRO_C
#include <string.h>
#ifdef sparc
#include <alloca.h>
#endif
#include "lisp.h"
......@@ -20,6 +21,10 @@ unsigned long binding_stack_size = BINDING_STACK_SIZE;
unsigned long static_space_size = STATIC_SPACE_SIZE;
unsigned long control_stack_size = CONTROL_STACK_SIZE;
#ifdef sparc
extern void make_holes(void);
#endif
static void
ensure_space(lispobj *start, size_t size)
{
......
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/vars.c,v 1.2 1994/10/25 00:21:19 ram Exp $ */
/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/vars.c,v 1.3 2004/07/08 17:49:04 rtoy Exp $ */
#include <stdio.h>
#include <sys/types.h>
#include <stdlib.h>
#include <string.h>
#include "lisp.h"
#include "vars.h"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment