+2008-02-29 Hans Boehm <Hans.Boehm@hp.com>
+
+ * pthread_support.c: Fix typo in comment.
+ * os_dep.c (GC_win32_get_mem): Add heap section only if
+ allocation succeeded.
+
2008-02-28 Hans Boehm <Hans.Boehm@hp.com>
* malloc.c: (free replacement) Fix caller address space check.
/* If I read the documentation correctly, this can */
/* only happen if HBLKSIZE > 64k or not a power of 2. */
if (GC_n_heap_bases >= MAX_HEAP_SECTS) ABORT("Too many heap sections");
- GC_heap_bases[GC_n_heap_bases++] = result;
+ if (0 != result) GC_heap_bases[GC_n_heap_bases++] = result;
return(result);
}
#if defined(GC_USE_DL_WRAP) || defined(GC_USE_DLOPEN_WRAP)
/* Define GC_ functions as aliases for the plain ones, which will */
/* be intercepted. This allows files which include gc.h, and hence */
-/* generate referemces to the GC_ symbols, to see the right symbols. */
+/* generate references to the GC_ symbols, to see the right symbols. */
int GC_pthread_create(pthread_t * t, const pthread_attr_t * a,
void * (* fn)(void *), void * arg) {
return pthread_create(t, a, fn, arg);