I've never seen this before and am perplexed beyond belief... by the way I'm using Visual Studio
I have a rather large program/game i'm working on right now, and it reads in via ifstream file i/o from binary files in several locations to initialize variables. For some reason for one set of files to read in it is opening and reading the wrong files, but only in release mode. Debug mode works like a charm, but in release it just won't work right. I'm getting strings longer than 4 bytes thrown into my ints and bunk values into others.
bool CParticleEffect::LoadEffect(char* fileName)
{
ifstream file;
file.open(fileName,ios_base::in | ios_base::binary);
if(!file.is_open())
{
ofstream problem;
problem.open("particle_problem.txt", ios_base::out | ios_base::trunc);
problem.write(fileName, sizeof(fileName));
return false;
}
i have that check at the begining to make sure the file is opening and it says that it is
has anyone seen or heard anything like this before... if so throw out a tip or give me a direction to look in... please. It would be greatly appreciated
Thanks