mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-03-15 23:22:53 +08:00
parse_execution: Remove dead tcgetattr code
This used to be assigned to the job, but that was removed in f30ce21aaa91a3ea1a3a871eed40b2971c551455. Since then this was vestigial. It could have technically errored out, but we should be catching that where we use the actual modes, not here.
This commit is contained in:
parent
b454b3bc40
commit
7b5667b11f
@ -7,7 +7,6 @@
|
|||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <termios.h>
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include <cwchar>
|
#include <cwchar>
|
||||||
@ -1307,15 +1306,6 @@ end_execution_reason_t parse_execution_context_t::run_1_job(const ast::job_pipel
|
|||||||
// We definitely do not want to execute anything if we're told we're --no-execute!
|
// We definitely do not want to execute anything if we're told we're --no-execute!
|
||||||
if (no_exec()) return end_execution_reason_t::ok;
|
if (no_exec()) return end_execution_reason_t::ok;
|
||||||
|
|
||||||
// Get terminal modes.
|
|
||||||
struct termios tmodes = {};
|
|
||||||
if (parser->is_interactive() && tcgetattr(STDIN_FILENO, &tmodes)) {
|
|
||||||
// Need real error handling here.
|
|
||||||
wperror(L"tcgetattr");
|
|
||||||
parser->set_last_statuses(statuses_t::just(STATUS_CMD_ERROR));
|
|
||||||
return end_execution_reason_t::error;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Increment the eval_level for the duration of this command.
|
// Increment the eval_level for the duration of this command.
|
||||||
scoped_push<int> saved_eval_level(&parser->eval_level, parser->eval_level + 1);
|
scoped_push<int> saved_eval_level(&parser->eval_level, parser->eval_level + 1);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user