simplify do_insertfile() by reusing variables where possible
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1951 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Этот коммит содержится в:
родитель
25884f3bdb
Коммит
03225330dc
@ -58,6 +58,7 @@ CVS code -
|
|||||||
do_insertfile()
|
do_insertfile()
|
||||||
- Readd the NANO_SMALL #ifdef around the start_again: label to
|
- Readd the NANO_SMALL #ifdef around the start_again: label to
|
||||||
avoid a warning. (DLR)
|
avoid a warning. (DLR)
|
||||||
|
- Simplify by reusing variables where possible. (DLR)
|
||||||
- global.c:
|
- global.c:
|
||||||
shortcut_init()
|
shortcut_init()
|
||||||
- Remove redundant NANO_SMALL #ifdef. (DLR)
|
- Remove redundant NANO_SMALL #ifdef. (DLR)
|
||||||
|
@ -520,13 +520,10 @@ void do_insertfile(void)
|
|||||||
}
|
}
|
||||||
#endif /* ENABLE_MULTIBUFFER */
|
#endif /* ENABLE_MULTIBUFFER */
|
||||||
if (i == NANO_EXTCMD_KEY) {
|
if (i == NANO_EXTCMD_KEY) {
|
||||||
char *ans = mallocstrcpy(NULL, answer);
|
int j = statusq(TRUE, extcmd_list, ans, NULL,
|
||||||
int ts = statusq(TRUE, extcmd_list, ans, NULL,
|
|
||||||
_("Command to execute"));
|
_("Command to execute"));
|
||||||
|
|
||||||
free(ans);
|
if (j == -1 || answer == NULL || answer[0] == '\0')
|
||||||
|
|
||||||
if (ts == -1 || answer == NULL || answer[0] == '\0')
|
|
||||||
goto start_again;
|
goto start_again;
|
||||||
}
|
}
|
||||||
#endif /* !NANO_SMALL */
|
#endif /* !NANO_SMALL */
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user