Page 1 of 1

A little issue with the INI file...

Posted: Mon Jan 30, 2006 1:22 pm
by Wanderer
Hi all

I have several datafiles i'm dealing with. If i have loaded a certain datafile and i try to change to another one via the datafile selector combo, i occasionally get the following message:

Error while loading datafile <the datafile i was about to load>
Cannot create file <my INI file>. The process cannot access the file because it is being used by another process.


There is no point in "create file <my INI file>" because my INI already exists. I believe it is being locked by another RC thread trying to update it or something. Eric, can this thing be avoided?

Posted: Tue Jan 31, 2006 12:38 pm
by RomCenter
No, I don't know. :?

I don't use thread in rc 2.x, so there should not be any problems with that.
Does it often happen ?

Posted: Tue Jan 31, 2006 2:10 pm
by Wanderer
RomCenter wrote:No, I don't know. :?

I don't use thread in rc 2.x, so there should not be any problems with that.
Does it often happen ?
It doesn't happen very often. Here's what i think happens (after i have used RC for some time):

I select a dat file. RC loads all paths and after it finishes, it (probably) tries to update the INI file with the info about the rom paths i have loaded. If at that time i select another path from the dat combo, it tries to read the INI file to retrieve info about the rom paths of the new dat file i selected and it cannot open it (because it is locked for writing) so it tries to recreate it. That probably produces the error.

It usually happens after i have used RC for some time and loaded several data files.

Posted: Wed Feb 01, 2006 9:09 am
by RomCenter
These events you describes happens synchronously, no threads. So I don't think this is the problem.
This error can happen when I open two times the ini file. I have to check if this is the case.