summaryrefslogtreecommitdiffstats
path: root/fdisk/fdisk.c
diff options
context:
space:
mode:
authorFrancesco Cosoleto2011-12-15 20:02:39 +0100
committerKarel Zak2011-12-16 14:04:00 +0100
commit883c5f715833b32137eac78f63b3517e9d1bda17 (patch)
treeabf5ce05952ebe34ecf4b73325547f67c7dea563 /fdisk/fdisk.c
parentfdisk: remove possibly_osf_label variable that is only assigned (diff)
downloadkernel-qcow2-util-linux-883c5f715833b32137eac78f63b3517e9d1bda17.tar.gz
kernel-qcow2-util-linux-883c5f715833b32137eac78f63b3517e9d1bda17.tar.xz
kernel-qcow2-util-linux-883c5f715833b32137eac78f63b3517e9d1bda17.zip
fdisk: move code for renaming SGI bootfile to SGI module
This moves the code for renaming SGI bootfile from command_prompt() to sgi_set_bootfilename() function. Signed-off-by: Francesco Cosoleto <cosoleto@gmail.com>
Diffstat (limited to 'fdisk/fdisk.c')
-rw-r--r--fdisk/fdisk.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/fdisk/fdisk.c b/fdisk/fdisk.c
index a23f45ee9..1a4c823ae 100644
--- a/fdisk/fdisk.c
+++ b/fdisk/fdisk.c
@@ -2906,15 +2906,9 @@ static void command_prompt(void)
unknown_command(c);
break;
case 'b':
- if (disklabel == SGI_LABEL) {
- printf(_("\nThe current boot file is: %s\n"),
- sgi_get_bootfile());
- if (read_chars(_("Please enter the name of the "
- "new boot file: ")) == '\n')
- printf(_("Boot file unchanged\n"));
- else
- sgi_set_bootfile(line_ptr);
- } else if (disklabel == DOS_LABEL) {
+ if (disklabel == SGI_LABEL)
+ sgi_set_bootfile();
+ else if (disklabel == DOS_LABEL) {
disklabel = OSF_LABEL;
bsd_command_prompt();
disklabel = DOS_LABEL;