terminal: Move re-edit detection to do_ecmd(). #5445

Closes #4784
This commit is contained in:
Harm te Hennepe
2016-10-07 16:19:43 +02:00
committed by Justin M. Keyes
parent cb351c678b
commit 538255c228
3 changed files with 11 additions and 5 deletions

View File

@@ -6726,11 +6726,6 @@ do_exedit (
old_curwin == NULL ? curwin : NULL);
} else if ((eap->cmdidx != CMD_split && eap->cmdidx != CMD_vsplit)
|| *eap->arg != NUL) {
// ":edit <blank>" is a no-op in terminal buffers. #2822
if (curbuf->terminal != NULL && eap->cmdidx == CMD_edit && *eap->arg == NUL) {
return;
}
/* Can't edit another file when "curbuf_lock" is set. Only ":edit"
* can bring us here, others are stopped earlier. */
if (*eap->arg != NUL && curbuf_locked())