Eliding an unneeded 'if'.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5617 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
12f27299f1
commit
98a8c06394
|
@ -3,6 +3,7 @@
|
||||||
when they have the default cursor position (line 1, column 1).
|
when they have the default cursor position (line 1, column 1).
|
||||||
* src/files.c (write_file): Avoid a pointless lstat() when not writing
|
* src/files.c (write_file): Avoid a pointless lstat() when not writing
|
||||||
to a temp file, and in the bargain elide two variables.
|
to a temp file, and in the bargain elide two variables.
|
||||||
|
* src/files.c (write_file): Elide an unneeded 'if'.
|
||||||
|
|
||||||
2016-02-06 Benno Schulenberg <bensberg@justemail.net>
|
2016-02-06 Benno Schulenberg <bensberg@justemail.net>
|
||||||
* src/files.c (write_file): Remove the --nofollow option that hasn't
|
* src/files.c (write_file): Remove the --nofollow option that hasn't
|
||||||
|
|
|
@ -1765,7 +1765,7 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type
|
||||||
/* The status fields filled in by stat(). */
|
/* The status fields filled in by stat(). */
|
||||||
char *realname;
|
char *realname;
|
||||||
/* name after tilde expansion. */
|
/* name after tilde expansion. */
|
||||||
FILE *f = NULL;
|
FILE *f = f_open;
|
||||||
/* The actual file, realname, we are writing to. */
|
/* The actual file, realname, we are writing to. */
|
||||||
char *tempname = NULL;
|
char *tempname = NULL;
|
||||||
/* The name of the temporary file we write to on prepend. */
|
/* The name of the temporary file we write to on prepend. */
|
||||||
|
@ -1775,9 +1775,6 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type
|
||||||
if (*name == '\0')
|
if (*name == '\0')
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
if (f_open != NULL)
|
|
||||||
f = f_open;
|
|
||||||
|
|
||||||
if (!tmp)
|
if (!tmp)
|
||||||
titlebar(NULL);
|
titlebar(NULL);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue