I am back with a possible cause:
I had threads in which I was independently malloc'ing memory and then free'ing it. I read here that free should be in exact reverse order as that of malloc calls.
Since threads are basically asynchronous, and there was no way of really enforcing the malloc-free call order.
Of course, I would want to know whether malloc-free call order is required across the threads.
Can someone at least confirm whether I thinking correctly?