Corrupted file at system level (cross-linked)
Posted on 2008-10-23
We have two programs that run on a Windows XP Embedded Kiosk machine. One program creates a file by opening it, writing a character, and then closing it. The other program simply checks for the
existence of the file like so:
if(PathFileExistsA( "C:\\FOLDER\FILENAME.TXT" ))
This file is written to ONLY when the program launches and is removed ONLY when the program closes (i.e. not continuosly). It is created like so:
m_pStartUpStream = fopen(strStartupFileName, "w");
Shutting the machine off periodically corrupts this file (ie. crosslinks) to the point where chkdsk has to be used to clean it up.