Source-Changes-HG archive

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

[src/netbsd-1-6]: src/distrib/utils/sysinst Pull up revision 1.41 (via patch)...



details:   https://anonhg.NetBSD.org/src/rev/f6bf5c6c201d
branches:  netbsd-1-6
changeset: 529150:f6bf5c6c201d
user:      lukem <lukem%NetBSD.org@localhost>
date:      Sun Oct 13 23:05:02 2002 +0000

description:
Pull up revision 1.41 (via patch) (requested by grant in ticket #853):
use current values for start/size/bsize/fsize as defaults when editing
disklabel partitions.

diffstat:

 distrib/utils/sysinst/menus.mi.fr |  16 +++++++++++-----
 1 files changed, 11 insertions(+), 5 deletions(-)

diffs (39 lines):

diff -r ab97cc07aaee -r f6bf5c6c201d distrib/utils/sysinst/menus.mi.fr
--- a/distrib/utils/sysinst/menus.mi.fr Sun Oct 13 23:04:54 2002 +0000
+++ b/distrib/utils/sysinst/menus.mi.fr Sun Oct 13 23:05:02 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: menus.mi.fr,v 1.35.2.2 2002/09/30 13:20:01 lukem Exp $ */
+/*     $NetBSD: menus.mi.fr,v 1.35.2.3 2002/10/13 23:05:02 lukem Exp $ */
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -145,8 +145,10 @@
        option "Offset/taille", action  
                {       int start, size;
                        msg_display_add(MSG_defaultunit, multname);
-                       start = getpartoff(MSG_offset, 0);
-                       size = getpartsize(MSG_size, start, 0);
+                       start = getpartoff(MSG_offset,
+                               bsdlabel[editpart].pi_offset);
+                       size = getpartsize(MSG_size, start,
+                               bsdlabel[editpart].pi_size);
                        if (size == -1)
                                size = dlsize - start;
                        bsdlabel[editpart].pi_offset = start;
@@ -160,10 +162,14 @@
                                process_menu (MENU_ok);
                                return FALSE;
                        }
-                       msg_prompt_add (MSG_bsize, NULL, buf, 40);
+                       snprintf(buf, sizeof(buf), "%d",
+                               bsdlabel[editpart].pi_bsize);
+                       msg_prompt_add (MSG_bsize, buf, buf, 40);
                        i = atoi(buf);
                        bsdlabel[editpart].pi_bsize = i;
-                       msg_prompt_add (MSG_fsize, NULL, buf, 40);
+                       snprintf(buf, sizeof(buf), "%d",
+                               bsdlabel[editpart].pi_fsize);
+                       msg_prompt_add (MSG_fsize, buf, buf, 40);
                        i = atoi(buf);
                        bsdlabel[editpart].pi_fsize = i;
                };



Home | Main Index | Thread Index | Old Index