rogue3: make LOGFILE work with SAVEDIR
This commit is contained in:
parent
acb1a4fce9
commit
bbec0d0514
3 changed files with 2 additions and 9 deletions
|
|
@ -38,6 +38,7 @@ char **envp;
|
|||
md_init(MD_STRIP_CTRL_KEYPAD);
|
||||
|
||||
open_score();
|
||||
open_log();
|
||||
|
||||
/*
|
||||
* check for print-score option
|
||||
|
|
|
|||
|
|
@ -119,17 +119,10 @@ open_score(void)
|
|||
#endif
|
||||
}
|
||||
|
||||
#if 0 /* not necessary */
|
||||
/* Same thing, but for the log file. Maybe combine them eventually. */
|
||||
/* FIXME you don't know what this does */
|
||||
void open_log(void)
|
||||
{
|
||||
#ifdef LOGFILE
|
||||
if (logfi != NULL) {
|
||||
rewind(logfi);
|
||||
return;
|
||||
}
|
||||
|
||||
logfi = fopen(LOGFILE, "a");
|
||||
|
||||
if (logfi == NULL)
|
||||
|
|
@ -142,7 +135,6 @@ void open_log(void)
|
|||
#endif
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* VARARGS2 */
|
||||
void
|
||||
|
|
@ -355,7 +347,6 @@ void writelog(int amount, int flags, int monst)
|
|||
else
|
||||
return;
|
||||
|
||||
logfi = fopen(LOGFILE, "a"); /* permissions? */
|
||||
if (logfi == NULL)
|
||||
return;
|
||||
/* and write it */
|
||||
|
|
|
|||
|
|
@ -609,6 +609,7 @@ void new_monster(struct linked_list *item, int type, coord *c
|
|||
struct linked_list * new_thing(void);
|
||||
char * num(int n1, int n2);
|
||||
void nohaste(void);
|
||||
void open_log(void);
|
||||
void open_score(void);
|
||||
void option(void);
|
||||
int pack_char(struct object *obj);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue