Mercurial > hg > xemacs-beta
diff src/mc-alloc.c @ 5042:f395ee7ad844
Fix some compile warnings, make vdb test code conditional on DEBUG_XEMACS
-------------------- ChangeLog entries follow: --------------------
src/ChangeLog addition:
2010-02-15 Ben Wing <ben@xemacs.org>
* mc-alloc.c:
* mc-alloc.c (mc_realloc_1):
* mc-alloc.c (set_dirty_bit):
* mc-alloc.c (set_dirty_bit_for_address):
* mc-alloc.c (get_dirty_bit):
* mc-alloc.c (get_dirty_bit_for_address):
* mc-alloc.c (set_protection_bit):
* mc-alloc.c (set_protection_bit_for_address):
* mc-alloc.c (get_protection_bit):
* mc-alloc.c (get_protection_bit_for_address):
* mc-alloc.c (get_page_start):
* vdb-win32.c (win32_fault_handler):
* vdb.c:
Fix some compile warnings, make vdb test code conditional on
DEBUG_XEMACS.
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Mon, 15 Feb 2010 21:52:39 -0600 |
parents | 93bd75c45dca |
children | 92dc90c0bb40 |
line wrap: on
line diff
--- a/src/mc-alloc.c Mon Feb 15 21:51:22 2010 -0600 +++ b/src/mc-alloc.c Mon Feb 15 21:52:39 2010 -0600 @@ -1,5 +1,6 @@ /* New size-based allocator for XEmacs. Copyright (C) 2005 Marcus Crestani. + Copyright (C) 2010 Ben Wing. This file is part of XEmacs. @@ -1578,7 +1579,7 @@ /* Changes the size of the cell pointed to by ptr. Returns the new address of the new cell with new size. */ -void * +static void * mc_realloc_1 (void *ptr, size_t size, int elemcount) { if (ptr) @@ -1782,25 +1783,25 @@ /*--- incremental garbage collector ----------------------------------*/ /* access dirty bit of page header */ -void +static void set_dirty_bit (page_header *ph, unsigned int value) { PH_DIRTY_BIT (ph) = value; } -void +static void set_dirty_bit_for_address (void *ptr, unsigned int value) { set_dirty_bit (get_page_header (ptr), value); } -unsigned int +static unsigned int get_dirty_bit (page_header *ph) { return PH_DIRTY_BIT (ph); } -unsigned int +static unsigned int get_dirty_bit_for_address (void *ptr) { return get_dirty_bit (get_page_header (ptr)); @@ -1808,25 +1809,25 @@ /* access protection bit of page header */ -void +static void set_protection_bit (page_header *ph, unsigned int value) { PH_PROTECTION_BIT (ph) = value; } -void +static void set_protection_bit_for_address (void *ptr, unsigned int value) { set_protection_bit (get_page_header (ptr), value); } -unsigned int +static unsigned int get_protection_bit (page_header *ph) { return PH_PROTECTION_BIT (ph); } -unsigned int +static unsigned int get_protection_bit_for_address (void *ptr) { return get_protection_bit (get_page_header (ptr)); @@ -1834,7 +1835,7 @@ /* Returns the start of the page of the object pointed to by ptr. */ -void * +static void * get_page_start (void *ptr) { return PH_HEAP_SPACE (get_page_header (ptr));