+-make default_fmode configurable, and add config
+ file command "chmod file mode"
-allow setting the new rcfile access rights.
-allow configuring the ttyrec dir location & file format.
fclose (canned);
fclose (newfile);
+ chmod (target, default_fmode);
}
#include "config.h"
#include <sys/param.h>
#include <sys/types.h>
+#include <sys/stat.h>
#include <time.h>
#ifndef ARRAY_SIZE
extern int num_games;
+extern mode_t default_fmode;
+
/* dgamelaunch.c */
extern void create_config(void);
extern void ttyrec_getmaster(void);
char *chosen_name;
int num_games = 0;
+mode_t default_fmode = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH;
+
struct dg_globalconfig globalconfig;
}
fclose (cannedf);
fclose (newfile);
+ chmod (p2, default_fmode);
}
break;
case DGLCMD_EXEC: