diff --git a/usr.sbin/sade/dispatch.c b/usr.sbin/sade/dispatch.c index 04cd77c6803e..2aa3fa962d71 100644 --- a/usr.sbin/sade/dispatch.c +++ b/usr.sbin/sade/dispatch.c @@ -45,6 +45,7 @@ static int dispatch_shutdown(dialogMenuItem *unused); static int dispatch_systemExecute(dialogMenuItem *unused); static int dispatch_msgConfirm(dialogMenuItem *unused); +static int dispatch_mediaClose(dialogMenuItem *unused); static struct _word { char *name; @@ -94,6 +95,7 @@ static struct _word { { "installVarDefaults", installVarDefaults }, { "loadConfig", dispatch_load_file }, { "loadFloppyConfig", dispatch_load_floppy }, + { "mediaClose", dispatch_mediaClose }, { "mediaSetCDROM", mediaSetCDROM }, { "mediaSetFloppy", mediaSetFloppy }, { "mediaSetDOS", mediaSetDOS }, @@ -205,6 +207,13 @@ dispatch_msgConfirm(dialogMenuItem *unused) return DITEM_FAILURE; } +static int +dispatch_mediaClose(dialogMenuItem *unused) +{ + mediaClose(); + return DITEM_SUCCESS; +} + static int call_possible_resword(char *name, dialogMenuItem *value, int *status) { diff --git a/usr.sbin/sade/sade.8 b/usr.sbin/sade/sade.8 index 55eca6b53d9f..1915960078c5 100644 --- a/usr.sbin/sade/sade.8 +++ b/usr.sbin/sade/sade.8 @@ -715,6 +715,11 @@ configuration file from another. .It configFile The fully qualified pathname of the file to load. .El +.It mediaClose +If a media device is open, close it. +.Pp +.Sy Variables : +None .It mediaSetCDROM Select a .Fx diff --git a/usr.sbin/sysinstall/dispatch.c b/usr.sbin/sysinstall/dispatch.c index 04cd77c6803e..2aa3fa962d71 100644 --- a/usr.sbin/sysinstall/dispatch.c +++ b/usr.sbin/sysinstall/dispatch.c @@ -45,6 +45,7 @@ static int dispatch_shutdown(dialogMenuItem *unused); static int dispatch_systemExecute(dialogMenuItem *unused); static int dispatch_msgConfirm(dialogMenuItem *unused); +static int dispatch_mediaClose(dialogMenuItem *unused); static struct _word { char *name; @@ -94,6 +95,7 @@ static struct _word { { "installVarDefaults", installVarDefaults }, { "loadConfig", dispatch_load_file }, { "loadFloppyConfig", dispatch_load_floppy }, + { "mediaClose", dispatch_mediaClose }, { "mediaSetCDROM", mediaSetCDROM }, { "mediaSetFloppy", mediaSetFloppy }, { "mediaSetDOS", mediaSetDOS }, @@ -205,6 +207,13 @@ dispatch_msgConfirm(dialogMenuItem *unused) return DITEM_FAILURE; } +static int +dispatch_mediaClose(dialogMenuItem *unused) +{ + mediaClose(); + return DITEM_SUCCESS; +} + static int call_possible_resword(char *name, dialogMenuItem *value, int *status) { diff --git a/usr.sbin/sysinstall/sysinstall.8 b/usr.sbin/sysinstall/sysinstall.8 index 55eca6b53d9f..1915960078c5 100644 --- a/usr.sbin/sysinstall/sysinstall.8 +++ b/usr.sbin/sysinstall/sysinstall.8 @@ -715,6 +715,11 @@ configuration file from another. .It configFile The fully qualified pathname of the file to load. .El +.It mediaClose +If a media device is open, close it. +.Pp +.Sy Variables : +None .It mediaSetCDROM Select a .Fx