Hello Bart,
new (just changed by TK Chia) https://github.com/tkchia/newlib-ia16/blob/newlib-2_4_0-ia16-tkchia/libgloss/ia16/dos-sbrk.c malloc returns NULL when the end of the heap is reached but this is not always checked properly in freecom, but at least it does not grow into the stack any more.
Yes, I finally got around to implementing the _heaplen variable from Turbo C into gcc-ia16. :) I hope to put out a new release of the whole gcc-ia16 toolchain after I have run the regression tests once through.
On the FreeCOM side, I find that the code to locate and patch _heaplen (utils/mkinfres.c, tools/ptchsize.c) will probably also need to be updated to handle the gcc-ia16 output. This turns out to be a bit trickier than I thought.
Thank you! -- https://github.com/tkchia/ _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel