fstream doesn't protect file?


This is more of a general question than a specific code question, but I think it fits into this forum. I was doing some file work. (I'm writing my own archiving software.) However, I noticed that when the file was open in my program it didn't protect it from other programs writing to it.

I'm opening the file like this:
std::fstream * test = new std::fstream("file.txt");

I think that this might be an issue especially if my program is seeking through the file.
Topic archived. No new replies allowed.