Thanks for the replies. We couldn't find errors in the code, but we do found that the Targa image files and sequences take huge amount of memory. We were using animated menu-s, and all the frames were different pictures (32bit with alpha channel), and these turned to be memory eating components. I guess we need to find another way of animating our menus.

Which leads to another question: Our game has and will have many graphic files (UI with all panels, textures and other small graphics.) Are they supposed to me in the memory all the time from the start of the game? Is There a way to load them only if they are needed and not at the beginning (for example the panels or the optional graphics that appear only if something is done), and to remove them from memory after we use them. We tried the "purge" function, but it doesn't seem to be changing the situation...