Moved do_possible_cd() function from main.c to execute.c.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2009-08-05 13:28:59 +04:00
parent d21c8dc448
commit cf2ecb4491
3 changed files with 13 additions and 13 deletions

View File

@ -98,6 +98,19 @@ pre_exec (void)
}
#ifdef HAVE_SUBSHELL_SUPPORT
static void
do_possible_cd (const char *new_dir)
{
if (!do_cd (new_dir, cd_exact))
message (D_ERROR, _("Warning"),
_(" The Commander can't change to the directory that \n"
" the subshell claims you are in. Perhaps you have \n"
" deleted your working directory, or given yourself \n"
" extra access permissions with the \"su\" command? "));
}
#endif /* HAVE_SUBSHELL_SUPPORT */
static void
do_execute (const char *shell, const char *command, int flags)
{

View File

@ -317,17 +317,6 @@ save_cwds_stat (void)
}
#ifdef HAVE_SUBSHELL_SUPPORT
void
do_possible_cd (const char *new_dir)
{
if (!do_cd (new_dir, cd_exact))
message (D_ERROR, _("Warning"),
_(" The Commander can't change to the directory that \n"
" the subshell claims you are in. Perhaps you have \n"
" deleted your working directory, or given yourself \n"
" extra access permissions with the \"su\" command? "));
}
void
do_update_prompt (void)
{

View File

@ -105,8 +105,6 @@ extern char *mc_home;
extern char *mc_home_alt;
char *get_mc_lib_dir (void);
void do_possible_cd (const char *dir);
void done_menu (void);
void init_menu (void);