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
619044e8
Commit
619044e8
authored
8 years ago
by
Benno Schulenberg
Browse files
Options
Download
Email Patches
Plain Diff
tweaks: put some conditions in a better order: the main one first
parent
e0e788e2
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/files.c
+3
-3
src/files.c
with
3 additions
and
3 deletions
+3
-3
src/files.c
View file @
619044e8
...
...
@@ -2250,7 +2250,7 @@ int do_writeout(bool exiting)
given
=
mallocstrcpy
(
NULL
,
#ifndef NANO_TINY
(
!
exiting
&&
openfile
->
mark_set
)
?
""
:
(
openfile
->
mark_set
&&
!
exiting
)
?
""
:
#endif
openfile
->
filename
);
...
...
@@ -2268,7 +2268,7 @@ int do_writeout(bool exiting)
* Selection to File" prompt. This function is disabled, since
* it allows reading from or writing to files not specified on
* the command line. */
if
(
!
ISSET
(
RESTRICTED
)
&&
!
exiting
&&
openfile
->
mark_set
)
if
(
openfile
->
mark_set
&&
!
exiting
&&
!
ISSET
(
RESTRICTED
)
)
msg
=
(
append
==
PREPEND
)
?
_
(
"Prepend Selection to File"
)
:
(
append
==
APPEND
)
?
_
(
"Append Selection to File"
)
:
_
(
"Write Selection to File"
);
...
...
@@ -2469,7 +2469,7 @@ int do_writeout(bool exiting)
* function is disabled, since it allows reading from or
* writing to files not specified on the command line. */
#ifndef NANO_TINY
if
(
!
ISSET
(
RESTRICTED
)
&&
!
exiting
&&
openfile
->
mark_set
)
if
(
openfile
->
mark_set
&&
!
exiting
&&
!
ISSET
(
RESTRICTED
)
)
result
=
write_marked_file
(
answer
,
NULL
,
FALSE
,
append
);
else
#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