]> skyeroc.xyz Git - dgamelaunch/commitdiff
I renamed it to 'bannerfile', 'banfile' is ambigous (perhaps for a future
authorBrett Carrington <brettcar@segvio.org>
Wed, 31 Dec 2003 20:21:00 +0000 (20:21 +0000)
committerBrett Carrington <brettcar@segvio.org>
Wed, 31 Dec 2003 20:21:00 +0000 (20:21 +0000)
banner users file?) Also made LOC_BANNER in the header and updated the
chroot script to include the banner and default-rc files.

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

dgamelaunch.c
dgamelaunch.h
dgl-create-chroot

index 752b086176c7e90e5fbaae2a54cce2d1264f745f..2653f1e6e6cecd823b4bf5a69401edd989a9f298 100644 (file)
@@ -160,14 +160,14 @@ catch_sighup ()
 void
 loadbanner (struct dg_banner *ban)
 {
-  FILE *banfile;
+  FILE *bannerfile;
   char buf[80];
 
   memset (buf, 0, 80);
 
-  banfile = fopen ("/dgl-banner", "r");
+  bannerfile = fopen (LOC_BANNER, "r");
 
-  if (!banfile)
+  if (!bannerfile)
     {
       ban->len = 2;
       ban->lines = malloc (sizeof (char *));
@@ -182,7 +182,7 @@ loadbanner (struct dg_banner *ban)
 
   ban->len = 0;
 
-  while (fgets (buf, 80, banfile) != NULL)
+  while (fgets (buf, 80, bannerfile) != NULL)
     {
       char *loc;
 
index 9c083cb96c58b345f049a042e53de0a660b22b1f..c38eba35ab1f4ca4611e9ec5cecda4710d08ed56 100644 (file)
@@ -30,5 +30,5 @@ struct dg_banner
 #define LOC_INPROGRESSDIR      LOC_DGLROOT "inprogress/"
 #define LOC_SPOOLDIR           "/var/mail"
 #define LOC_CANNED             "/dgl-default-rcfile"
-
+#define LOC_BANNER             "/dgl-banner"
 #endif
index 66ebb56c9cb998e0b1e4faf354cbe21608f05d85..d9c7f8f78638e6e0186a756dad6a2b33081d88cf 100755 (executable)
@@ -29,6 +29,11 @@ chown -R $CHROOT_UID:$CHROOT_GID $CHROOT_PATH/dgldir
 chown -R $CHROOT_UID:$CHROOT_GID $CHROOT_PATH/var/mail
 touch $CHROOT_PATH/dgl-login
 touch $CHROOT_PATH/dgl-lock
+
+# Might want to remove these two for packaging?
+cp dgl-default-rcfile $CHROOT_PATH/
+cp dgl-banner $CHROOT_PATH/
+
 chown $CHROOT_UID:$CHROOT_GID $CHROOT_PATH/dgl-*
 
 # Needs gzip to compress