I am making a simple game - I have vector of structures and I want to write values to simple text file.
end of my code :
	
	
	
		
I have created a file with pre-defined values (name+score). Program reads values, modifies them and writes them into a text file (the same of course). I can see in main menu that values change. When I exit program to GP2X menu and run program again everything is OK - values are changed. But when I turn off GP2X and start it and run my program values are NOT changed.
Why ?!
				
			end of my code :
		Code:
	
			ofstream fout;
					   ...
					   ...
	fout.open(HISCORE_PATH);	
	for (int i = 0; i<=9; i++)
	{
		fout<<hiscore[i].score<<endl;
		fout<<hiscore[i].name<<endl;
	}
	fout.close();
	SDL_Quit();
	
	chdir("/usr/gp2x");
	execl("/usr/gp2x/gp2xmenu", "/usr/gp2x/gp2xmenu", NULL);
	
	return 0;
}
	I have created a file with pre-defined values (name+score). Program reads values, modifies them and writes them into a text file (the same of course). I can see in main menu that values change. When I exit program to GP2X menu and run program again everything is OK - values are changed. But when I turn off GP2X and start it and run my program values are NOT changed.
Why ?!
	