diff options
Diffstat (limited to 'fdisks/fdisk-menu.c')
| -rw-r--r-- | fdisks/fdisk-menu.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/fdisks/fdisk-menu.c b/fdisks/fdisk-menu.c index 72513072..d842b813 100644 --- a/fdisks/fdisk-menu.c +++ b/fdisks/fdisk-menu.c @@ -108,6 +108,7 @@ struct menu menu_generic = { MENU_ENT_L('w', N_("write table to disk"), FDISK_DISKLABEL_BSD), MENU_BENT ('q', N_("quit without saving changes")), MENU_XENT ('r', N_("return to main menu")), + MENU_ENT_L('r', N_("return to main menu"), FDISK_DISKLABEL_BSD), { 0, NULL } } @@ -483,16 +484,13 @@ static int generic_menu_cb(struct fdisk_context **cxt0, case 'r': /* return from nested PT (e.g. BSD) */ if (cxt->parent) { - struct fdisk_context *tmp = cxt->parent; + *cxt0 = cxt->parent; fdisk_info(cxt, _("Leaving nested disk label.")); fdisk_free_context(cxt); - cxt = tmp; + cxt = *cxt0; } break; - default: - fdisk_warnx(cxt, _("%c: unimplemented command"), ent->key); - break; } return rc; |
