Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
cs24-19fa
git_rec_nano
Commits
c1bb6485
Commit
c1bb6485
authored
7 years ago
by
Benno Schulenberg
Browse files
Options
Download
Email Patches
Plain Diff
tweaks: check for the type of terminal far earlier
So the result could be used during RC-file reading.
parent
4bcce96a
master
feature/match-parens
refactor/readbility
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/nano.c
+5
-5
src/nano.c
with
5 additions
and
5 deletions
+5
-5
src/nano.c
View file @
c1bb6485
...
...
@@ -1980,6 +1980,11 @@ int main(int argc, char **argv)
{
NULL
,
0
,
NULL
,
0
}
};
#ifdef __linux__
/* Check whether we're running on a Linux console. */
console
=
(
getenv
(
"DISPLAY"
)
==
NULL
);
#endif
/* Back up the terminal settings so that they can be restored. */
tcgetattr
(
0
,
&
oldterm
);
...
...
@@ -2471,11 +2476,6 @@ int main(int argc, char **argv)
/* Set up the terminal state. */
terminal_init
();
#ifdef __linux__
/* Check whether we're running on a Linux console. */
console
=
(
getenv
(
"DISPLAY"
)
==
NULL
);
#endif
#ifdef DEBUG
fprintf
(
stderr
,
"Main: set up windows
\n
"
);
#endif
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help