]> skyeroc.xyz Git - dgamelaunch/commitdiff
- no need for strdup, we never free myconfig
authorJoshua Kwan <joshk@triplehelix.org>
Wed, 21 Jan 2004 16:47:30 +0000 (16:47 +0000)
committerJoshua Kwan <joshk@triplehelix.org>
Wed, 21 Jan 2004 16:47:30 +0000 (16:47 +0000)
- use defconfig for default passwd/lockfile

git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@145 db0b04b0-f4d1-0310-9a6d-de3e77497b0e

dgamelaunch.c

index 727097acaaaeb85c4e71cadadaa7d2b5dee7f416..a4e8e17f72e85aea1abf09376c0cdc3f213c162b 100644 (file)
@@ -192,12 +192,14 @@ create_config ()
     }
 
     if (myconfig->max == 0) myconfig->max = defconfig.max;
-    if (!myconfig->banner) myconfig->banner = strdup(defconfig.banner);
-    if (!myconfig->chroot) myconfig->chroot = strdup(defconfig.chroot);
-    if (!myconfig->nethack) myconfig->nethack = strdup(defconfig.nethack);
-    if (!myconfig->dglroot) myconfig->dglroot = strdup(defconfig.dglroot);
-    if (!myconfig->rcfile) myconfig->rcfile = strdup(defconfig.rcfile);
-    if (!myconfig->spool) myconfig->spool = strdup(defconfig.spool);
+    if (!myconfig->banner) myconfig->banner = defconfig.banner;
+    if (!myconfig->chroot) myconfig->chroot = defconfig.chroot;
+    if (!myconfig->nethack) myconfig->nethack = defconfig.nethack;
+    if (!myconfig->dglroot) myconfig->dglroot = defconfig.dglroot;
+    if (!myconfig->rcfile) myconfig->rcfile = defconfig.rcfile;
+    if (!myconfig->spool) myconfig->spool = defconfig.spool;
+    if (!myconfig->passwd) myconfig->passwd = defconfig.passwd;
+    if (!myconfig->lockfile) myconfig->lockfile = defconfig.lockfile;
   }
   else
   {