Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-2-0]: src/distrib/utils/sysinst Pull up revision 1.44 (requested ...



details:   https://anonhg.NetBSD.org/src/rev/07b15c0eec90
branches:  netbsd-2-0
changeset: 561325:07b15c0eec90
user:      tron <tron%NetBSD.org@localhost>
date:      Mon Jun 07 10:20:32 2004 +0000

description:
Pull up revision 1.44 (requested by dsl in ticket #453):
A load of usability fixes mainly to network installs.
I've made the error retry loops go back as far as the input menus.
Split all the pathname inputs into 2 pieces (base directory and set directory).
Reduced the size of some fixed strings.
Stopped the install aborting if ftp can't find a set (eg the X ones).
The French and Polish transations don't differenciate between Base_dir and
Set_dir - but that can be fixed later.

diffstat:

 distrib/utils/sysinst/main.c |  38 +++-----------------------------------
 1 files changed, 3 insertions(+), 35 deletions(-)

diffs (93 lines):

diff -r 1b9c99ec9065 -r 07b15c0eec90 distrib/utils/sysinst/main.c
--- a/distrib/utils/sysinst/main.c      Mon Jun 07 10:20:27 2004 +0000
+++ b/distrib/utils/sysinst/main.c      Mon Jun 07 10:20:32 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.42.2.1 2004/05/22 16:23:58 he Exp $ */
+/*     $NetBSD: main.c,v 1.42.2.2 2004/06/07 10:20:32 tron Exp $       */
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -61,7 +61,6 @@
 static void miscsighandler(int);
 static void ttysighandler(int);
 static void cleanup(void);
-static void set_defaults(void);
 static void process_f_flag(char *);
 
 static int exit_cleanly = 0;   /* Did we finish nicely? */
@@ -112,8 +111,6 @@
                        usage();
                }
 
-       set_defaults();
-
        md_init();
 
        /* initialize message window */
@@ -364,32 +361,6 @@
                fprintf(stderr, "\n\nsysinst terminated.\n");
 }
 
-static void
-set_defaults(void)
-{
-
-       /*
-        * Set defaults for ftp_dir & cdrom_dir, by appending ftp_prefix.
-        * This occurs even when the settings are read in from
-        * "-f definition-file".
-        *
-        * Default values (can be changed in definition-file):
-        *      ftp_dir                 SYSINST_FTP_DIR
-        *      SYSINST_FTP_DIR         "pub/NetBSD/NetBSD-" + REL + "/" MACH
-        *                      
-        *      cdrom_dir               SYSINST_CDROM_DIR
-        #      SYSINST_CDROM_DIR       "/" + MACH
-        *
-        *      ftp_prefix              "/binary/sets"
-        */
-       
-               /* ftp_dir += ftp_prefix */
-       strlcat(ftp_dir, ftp_prefix, STRSIZE);
-
-               /* cdrom_dir += ftp_prefix */
-       strlcat(cdrom_dir, ftp_prefix, STRSIZE);
-}
-
 
 /* Stuff for processing the -f file argument. */
 
@@ -401,14 +372,13 @@
 static char *ext_dir_ptr = ext_dir;
 static char *ftp_host_ptr = ftp_host;
 static char *ftp_dir_ptr = ftp_dir;
-static char *ftp_prefix_ptr = ftp_prefix;
+static char *set_dir_ptr = set_dir;
 static char *ftp_user_ptr = ftp_user;
 static char *ftp_pass_ptr = ftp_pass;
 static char *ftp_proxy_ptr = ftp_proxy;
 static char *nfs_host_ptr = nfs_host;
 static char *nfs_dir_ptr = nfs_dir;
 static char *cdrom_dev_ptr = cdrom_dev;
-static char *cdrom_dir_ptr = cdrom_dir;
 static char *localfs_dev_ptr = localfs_dev;
 static char *localfs_fs_ptr = localfs_fs;
 static char *localfs_dir_ptr = localfs_dir;
@@ -423,8 +393,7 @@
        {"ext dir", "ext dir = %s", "a $0", &ext_dir_ptr, 1, STRSIZE, NULL},
        {"ftp host", "ftp host = %s", "a $0", &ftp_host_ptr, 1, STRSIZE, NULL},
        {"ftp dir", "ftp dir = %s", "a $0", &ftp_dir_ptr, 1, STRSIZE, NULL},
-       {"ftp prefix", "ftp prefix = %s", "a $0", &ftp_prefix_ptr, 1,
-               STRSIZE, NULL},
+       {"ftp prefix", "set dir = %s", "a $0", &set_dir_ptr, 1, STRSIZE, NULL},
        {"ftp user", "ftp user = %s", "a $0", &ftp_user_ptr, 1, STRSIZE, NULL},
        {"ftp pass", "ftp pass = %s", "a $0", &ftp_pass_ptr, 1, STRSIZE, NULL},
        {"ftp proxy", "ftp proxy = %s", "a $0", &ftp_proxy_ptr, 1, STRSIZE,
@@ -432,7 +401,6 @@
        {"nfs host", "nfs host = %s", "a $0", &nfs_host_ptr, 1, STRSIZE, NULL},
        {"nfs dir", "ftp dir = %s", "a $0", &nfs_dir_ptr, 1, STRSIZE, NULL},
        {"cd dev", "cd dev = %s", "a $0", &cdrom_dev_ptr, 1, STRSIZE, NULL},
-       {"cd dir", "cd dir = %s", "a $0", &cdrom_dir_ptr, 1, STRSIZE, NULL},
        {"local dev", "local dev = %s", "a $0", &localfs_dev_ptr, 1, STRSIZE,
                NULL},
        {"local fs", "local fs = %s", "a $0", &localfs_fs_ptr, 1, STRSIZE,



Home | Main Index | Thread Index | Old Index