Tamas Rudnai wrote: > If there is not enough memory, then your application would fail anyway. > One must be careful enough to make the application recover gracefully > from such failure. > >Exactly. You need to know how much memory your application is going to use in worse scenario anyway. The matter of fact it is harder to predict or calculate it with dynamic memory handling as there are some other factors like the fragmentation, memory leaks and other memory unbalancing problems. In addition to this buffer overflow problems can also corrupt the memory mapping structure which elevates the problem to a big and hardly recoverable problem.< Tamas, you should go back and re-read Isaac's email. :) I second everything he said. As with everything in engineering, we're dealing with tradeoffs. Potentially dangerous but flexible versus safe and rigid. Of course you have to be careful when using dynamic memory allocation, but you can't just assume that if you use it you will have memory leaks, memory unbalancing problems, and "big and hardly recoverable problem". You don't need malloc() to write buggy code. I think what Isaac meant is that if your application doesn't have enough memory to do what it needs to do, you should get a chip with more RAM! Vitaliy -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist