]> skyeroc.xyz Git - dgamelaunch/commitdiff
Quick fix
authorJoshua Kwan <joshk@triplehelix.org>
Mon, 5 Jan 2004 01:57:25 +0000 (01:57 +0000)
committerJoshua Kwan <joshk@triplehelix.org>
Mon, 5 Jan 2004 01:57:25 +0000 (01:57 +0000)
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@84 db0b04b0-f4d1-0310-9a6d-de3e77497b0e

dgamelaunch.c

index f8a202df0271f1bb8867424b25a338cc7b315d09..1455190d9be0f4cc62f29798a2dbe1151d67a371 100644 (file)
@@ -158,6 +158,7 @@ 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);
@@ -1318,7 +1319,7 @@ purge_stale_locks (void)
 }
 
 int
-main (void)
+main (int argc, char** argv)
 {
   /* for chroot and program execution */
   char atrcfilename[81], *spool;
@@ -1327,6 +1328,9 @@ main (void)
 
   int userchoice = 0;
 
+  if (argc == 2)
+    config = strdup(argv[1]);
+  
   create_config();
 
   /* coredumper */