Olin Lathrop escreveu: > Vitaliy wrote: > = >> FWIW, we use dynamic memory allocation in all of our current projects >> (on 24H and 33F). >> >> ... >> >> Memory gets allocated during initialization and doesn't change. >> = > > These two statements seem to be at odds with each other. > = I write applications with lots of allocations and deallocations and never had any problems. With good planning I can guarantee that fragmentation will not make the application fail. Most systems could be designed not to use dynamic allocation, but it is much easier and flexible (and portable) with it. Why struggle with hard to understand code, defining lots of unions if you can just allocate some memory. Sometimes it is just not possible to predetermine how many of what structures you are going to need in every scenario. With unions of overlapped structures you must have this knowledge at design time. 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. Regards, Isaac __________________________________________________ Fa=E7a liga=E7=F5es para outros computadores com o novo Yahoo! Messenger = http://br.beta.messenger.yahoo.com/ = -- = http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist