# HG changeset patch # User elwin # Date 1344718704 0 # Node ID 88dc6813e36ab3f0560e037a1b137dbdc9b362b6 # Parent 7a7fb9b810e19f33bc7c242c72a2b7694e68e4e8 arogue5: update the score list before prompting to exit. diff -r 7a7fb9b810e1 -r 88dc6813e36a arogue5/rip.c --- a/arogue5/rip.c Sat Aug 11 18:56:32 2012 +0000 +++ b/arogue5/rip.c Sat Aug 11 20:58:24 2012 +0000 @@ -472,6 +472,13 @@ } } + fseek(outf, 0L, 0); + /* + * Update the list file + */ + scoreout(top_ten, outf); + fclose(outf); + /* * SCOREIT -- rogue -s option. Never started curses if this option. * UPDATE -- network scoring update. Never started curses if this option. @@ -557,19 +564,14 @@ else printf("\n"); } } - if ((flags != SCOREIT) && (flags != UPDATE)) { - printf("\n[Press return to exit]"); - fflush(stdout); - fgets(prbuf,80,stdin); - } /* if (prflags == EDITSCORE) endwin(); */ /* End editing windowing */ } - fseek(outf, 0L, 0); - /* - * Update the list file - */ - scoreout(top_ten, outf); - fclose(outf); + + if ((flags != SCOREIT) && (flags != UPDATE)) { + printf("\n[Press return to exit]"); + fflush(stdout); + fgets(prbuf,80,stdin); + } } void writelog(unsigned long amount, int flags, short monst) {