U just found and solved a nasty bug… a memory leak was found inside function for polynominal long division. Typically, I was creating more objects than I was deleting.

Not sure how long this bug was resident in the code. Certainly it already is present in 1.4 version. Somehow, the bug became more apparent after I replaced all malloc calls with HeapAlloc calls. (Yes, I found that the HeapAlloc works much faster than the malloc. Furthermore, the calloc is worst of them all – making malloc and then clearing memory is much faster than calling calloc. Strange indeed.)

Advertisements