Can't get past [Press SPACE to continue] upon locked highscore file
issueid=2159 05-27-2013 03:41 PM
Senior Member
Number of reported issues by Alucard: 22
Can't get past [Press SPACE to continue] upon locked highscore file
Killing from another place necessary

1. rm -rf ~/
2. mkdir ~/
3. touch ~/
4. Start ADOM, start a game, leave the chain, answer y/n prompts
5. Read "The highscore has been locked for a long time. Some kind of problem with / another ADOM process might be the reason for this. You might be in trouble... / [Press SPACE to continue]"
6. Press space
7. Repeat steps 5-6 ad infinitum

There seems to be no provision for a hi score lock file that is never removed. This can happen for example when a Pre6 ADOM locks then tries to read a hi score file that's been touched by Pre14 and segfaults, leaving the lock file behind.
The window has to be force closed, or the game killed from another terminal, and the lock file removed manually.


* Give up after 3-5 presses (print "N tries remaining"), or
* Give option to give up ("Press Q to give up"), and/or
* Read the lock file and print "Process #NNNN seems to be holding it open" with a recommendation to kick it or remove the lock file if the process is not still running

Actually, rereading #2158 I think this is one of the problems reported there.
Issue Details
Issue Number 2159
Project ADOM (Ancient Domains Of Mystery)
Category Linux
Status Fixed
Priority 3
Affected Version ADOM 1.2.0 pre 14
Fixed Version ADOM 1.2.0 pre 15
Milestone (none)
Users able to reproduce bug 0
Users unable to reproduce bug 0
Assigned Users (none)
Tags (none)

05-27-2013 06:05 PM
jt jt is offline
Sounds like a good idea. I'm not sure if there is an easy way to detect the process ID that still might have locked the highscore, but a menu like the following might help.

a) "retry": try again
b) "give up": without storing the highscore
c) "force": write the highscore and delete the lock file

05-27-2013 06:34 PM
Senior Member
The ADOM_HS.LCK file contains the PID that placed it (when placed by the game)-

Locked be thee! (says process NNNN)

05-27-2013 06:53 PM
jt jt is offline
Ok, thanks... that's some of Thomas' old code that I've never touched. ;)

08-07-2013 10:25 AM
jt jt is offline
Fixed for both highscore and achievements lock file.

+ Reply