File Destruction

can somebody help me out?

i need to destroy files against microscopy. this means i need to physically overwrite the file 36 times. however, commanding to write to the file using the fstream stuff only tells Windows "change that there file" and Windows considers the physical change later due to possible other changes to the file, writing to the file, physically, only once in a while the current version from some kind of buffer or so.

therefore, i have heard, i must synchronize after each of the 36 writings to the file so each becomes physical writing. but i don't know any C++ command to tell Windows to synchronize. any idea?

btw: i'm using Bloodshed Dev C++ compiler. and my platform: Windows 2000 Professional.


tx Tinky
Last edited on
http://www.heidi.ie/eraser/ does this. You can download the source to study it.
thanx so much. this helps a freaking lot.

didn't know sourceforge at all. knew that there must be something like it, but didn't find it yet.

if somebody's interested: the command i'm looking for, i now believe, is streambuf::pubsync. but me, i'll study that source code. cos there's no feedback from the compiled program if the physical drive is really not microscopable. and maybe there are other problems.

so thanx again and have a good one


Tinky
Topic archived. No new replies allowed.