Hello, i was trying to write some code that uses MEMORY_FILE as a buffer and write that buffer to the output file, clear it and use it again and again. I was trying to clear MEMORY_FILE after each write, didn't found any info regarding how to do (maybe it's not possible, don't know).
Could somebody give some help?
Working with MEMORY_FILE
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Working with MEMORY_FILE
log MEMORY_FILE 0 0
-
- Posts: 3
- Joined: Wed Sep 16, 2020 2:08 pm
Re: Working with MEMORY_FILE
aluigi wrote:log MEMORY_FILE 0 0
Thank you for the reply, that's what i've tried for first. The strange thing is that the memory_file size keep increasing, seems the command has no effect.
-
- Site Admin
- Posts: 12984
- Joined: Wed Jul 30, 2014 9:32 pm
Re: Working with MEMORY_FILE
Are you sure you don't have the "append" mode left enabled?
The size of the MEMORY_FILE in memory is not touched after reset because it's left as buffer for possible future operations, in this case it improves the performances by avoiding to reallocate it multiple times.
So if you still see quickbms.exe keeping lot of memory after "log MEMORY_FILE 0 0" that's normal
The size of the MEMORY_FILE in memory is not touched after reset because it's left as buffer for possible future operations, in this case it improves the performances by avoiding to reallocate it multiple times.
So if you still see quickbms.exe keeping lot of memory after "log MEMORY_FILE 0 0" that's normal
-
- Posts: 3
- Joined: Wed Sep 16, 2020 2:08 pm
Re: Working with MEMORY_FILE
aluigi wrote:Are you sure you don't have the "append" mode left enabled?
The size of the MEMORY_FILE in memory is not touched after reset because it's left as buffer for possible future operations, in this case it improves the performances by avoiding to reallocate it multiple times.
So if you still see quickbms.exe keeping lot of memory after "log MEMORY_FILE 0 0" that's normal
Now that you mentioned, i think i've used append at the beggining, let me check. Thank you, you did a great tool man!