malloc hangs indefinitely
Earl H. Kinmonth
ked at garnet.berkeley.edu
Tue Jan 31 15:33:01 AEST 1989
In article <489 at marob.MASA.COM> daveh at marob.masa.com (Dave Hammond) writes:
>space in its heap. Any suggestions on what might cause malloc to
>spin its wheels? Have I perhaps trashed malloc's heap list?
In those versions of malloc where the heap list is maintained through
a header just before the portion returned to you, this is very probable.
Copy a too long string into an area returned by malloc or assign with
a negative subscript and you will often do this.
More information about the Comp.lang.c
mailing list