using up ram when saving to file...

Blitz3D Forums/Blitz3D Programming/using up ram when saving to file...

Swifty(Posted 2007) [#1]
I have a game program running that saves player data at reqular intervals, this is data that would be used in later sessions.

An issue I have run into is that with the save function active , Task Manager shows memory usage increasing, which I believe is a memory leak symptom.

Am I opening and closing the file correctly...?

dir$="players\"+p\user$+"\"+p\name$+"\cords.dat"
fileout=WriteFile(dir$)
WriteString(fileout,p\cord$)
CloseFile(fileout)

dir$=""
fileout=0


Any help on why memory use would increase by using this function would be welcome.

BB3D version 1.98


Subirenihil(Posted 2007) [#2]
My initial thought is that Windows might be storing the file in RAM and never bothering to clear the RAM until necessary.
However, I will look into this somemore...


Swifty(Posted 2007) [#3]
Yeah I was wondering if windows is holding it in ram...