diff options
author | Benedikt Meurer <benedikt.meurer@googlemail.com> | 2012-12-29 10:41:08 +0000 |
---|---|---|
committer | Benedikt Meurer <benedikt.meurer@googlemail.com> | 2012-12-29 10:41:08 +0000 |
commit | b04d8284f0ce84d237cadf8ff5aabc060890613f (patch) | |
tree | f44b7273a42c0473e03b6b9f9c701147fdd1a33e /byterun/gc_ctrl.c | |
parent | 21735ad37520e466ff6b32474964d3206ab4dbef (diff) |
Fix several C compiler warnings.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13171 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'byterun/gc_ctrl.c')
-rw-r--r-- | byterun/gc_ctrl.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/byterun/gc_ctrl.c b/byterun/gc_ctrl.c index 8950bb662..07cfc26d2 100644 --- a/byterun/gc_ctrl.c +++ b/byterun/gc_ctrl.c @@ -127,7 +127,10 @@ static value heap_stats (int returnstats) free_words = 0, free_blocks = 0, largest_free = 0, fragments = 0, heap_chunks = 0; char *chunk = caml_heap_start, *chunk_end; - char *cur_hp, *prev_hp; + char *cur_hp; +#ifdef DEBUG + char *prev_hp; +#endif header_t cur_hd; #ifdef DEBUG @@ -137,7 +140,9 @@ static value heap_stats (int returnstats) while (chunk != NULL){ ++ heap_chunks; chunk_end = chunk + Chunk_size (chunk); +#ifdef DEBUG prev_hp = NULL; +#endif cur_hp = chunk; while (cur_hp < chunk_end){ cur_hd = Hd_hp (cur_hp); @@ -192,7 +197,9 @@ static value heap_stats (int returnstats) */ break; } +#ifdef DEBUG prev_hp = cur_hp; +#endif cur_hp = Next (cur_hp); } Assert (cur_hp == chunk_end); chunk = Chunk_next (chunk); |