]> skyeroc.xyz Git - dgamelaunch/commitdiff
some fixes
authorJoshua Kwan <joshk@triplehelix.org>
Mon, 5 Jan 2004 17:27:49 +0000 (17:27 +0000)
committerJoshua Kwan <joshk@triplehelix.org>
Mon, 5 Jan 2004 17:27:49 +0000 (17:27 +0000)
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@92 db0b04b0-f4d1-0310-9a6d-de3e77497b0e

Changelog
dgamelaunch.c
dgamelaunch.h

index 72d461106a4c6ed0be0e7344d66cb580a1fe15b4..3eb4461d5be5eaa5d219e3448005e95e1dba46f6 100644 (file)
--- a/Changelog
+++ b/Changelog
@@ -29,6 +29,8 @@
        * Make sure only one session can be played at once at all and
          SIGHUP the rest, ensuring the death of "Destroy old game? [yn]"
        * Replace two colossal conditionals with calls to isalnum(3).
+       * Shift from static #defines to a configuration file system
+         powered by lex/yacc.
 
 1.3.10 (2003/10/22)
        * Added a mode flag to the open call for inprogress lock files.
index 1455190d9be0f4cc62f29798a2dbe1151d67a371..c4c720cbb497886c757fefa345679f5f18ffed5d 100644 (file)
@@ -1040,7 +1040,7 @@ readfile (int nolock)
 
       f_num++;
       /* prevent a buffer overrun here */
-      if (f_num >= MAXUSERS)
+      if (f_num >= myconfig->max)
         graceful_exit (109);
     }
 
index 60a0b4b4d68274fd66f25d9cfb755758f0b715a1..73eb67657c436e4e24a3ca0236790a8fa378627d 100644 (file)
@@ -53,20 +53,6 @@ extern char* config; /* file path */
 extern struct dg_config *myconfig;
 extern struct dg_config defconfig;
 
-#define SHED_UID 5              /* the uid to shed privs to */
-#define SHED_GID 60             /* the gid to shed privs to */
-#define MAXUSERS 64000          /* solves some preallocation issues. */
-
-#define LOC_CHROOT             "/var/lib/dgamelaunch/"
-#define LOC_NETHACK            "/bin/nethack"
-#define LOC_DGLROOT            "/dgldir/"
-#define LOC_DGLDIR             LOC_DGLROOT "rcfiles/"
-#define LOC_TTYRECDIR          LOC_DGLROOT "ttyrec/"
-#define LOC_INPROGRESSDIR      LOC_DGLROOT "inprogress/"
-#define LOC_SPOOLDIR           "/var/mail"
-#define LOC_CANNED             "/dgl-default-rcfile"
-#define LOC_BANNER             "/dgl-banner"
-
 /* dgamelaunch.c function prototypes */
 extern void create_config (void);
 extern void ttyrec_getmaster (void);