Browse Source

Merge branch 'jk/pack-bitmap'

A last minute (and hopefully the last) fix to avoid coredumps due
to an incorrect pointer arithmetic.

* jk/pack-bitmap:
  ewah_bitmap.c: do not assume size_t and eword_t are the same size
maint
Junio C Hamano 11 years ago
parent
commit
1697bf30df
  1. 2
      ewah/ewah_bitmap.c

2
ewah/ewah_bitmap.c

@ -41,7 +41,7 @@ static inline void buffer_grow(struct ewah_bitmap *self, size_t new_size) @@ -41,7 +41,7 @@ static inline void buffer_grow(struct ewah_bitmap *self, size_t new_size)
self->alloc_size = new_size;
self->buffer = ewah_realloc(self->buffer,
self->alloc_size * sizeof(eword_t));
self->rlw = self->buffer + (rlw_offset / sizeof(size_t));
self->rlw = self->buffer + (rlw_offset / sizeof(eword_t));
}

static inline void buffer_push(struct ewah_bitmap *self, eword_t value)

Loading…
Cancel
Save