(exit_subshell): return gboolean instead of int.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2012-10-29 16:38:28 +04:00
parent d1fb83358d
commit c45a27061b
3 changed files with 7 additions and 7 deletions

View File

@ -1054,7 +1054,7 @@ quit_cmd_internal (int quiet)
#ifdef ENABLE_SUBSHELL
if (!mc_global.tty.use_subshell)
stop_dialogs ();
else if ((q = exit_subshell ()))
else if ((q = exit_subshell () ? 1 : 0) != 0)
#endif
stop_dialogs ();
}

View File

@ -1050,16 +1050,16 @@ do_update_prompt (void)
/* --------------------------------------------------------------------------------------------- */
int
gboolean
exit_subshell (void)
{
int subshell_quit = TRUE;
gboolean subshell_quit = TRUE;
if (subshell_state != INACTIVE && subshell_alive)
subshell_quit =
!query_dialog (_("Warning"),
_("The shell is still active. Quit anyway?"),
D_NORMAL, 2, _("&Yes"), _("&No"));
query_dialog (_("Warning"),
_("The shell is still active. Quit anyway?"),
D_NORMAL, 2, _("&Yes"), _("&No")) == 0;
if (subshell_quit)
{

View File

@ -42,7 +42,7 @@ void init_subshell (void);
int invoke_subshell (const char *command, int how, vfs_path_t ** new_dir);
int read_subshell_prompt (void);
void do_update_prompt (void);
int exit_subshell (void);
gboolean exit_subshell (void);
void do_subshell_chdir (const vfs_path_t * vpath, gboolean update_prompt, gboolean reset_prompt);
void subshell_get_console_attributes (void);
void sigchld_handler (int sig);