The lack of initialization caused a nasty bug on some targets (such as
ARMv7) which would make it so that ^S would just say "Cancelled".
While x86 (both 64 and 32 bits) seems to initialize 'response' to zero or
a positive number, ARM does not, and there is usually a negative value in
its place, which triggers the 'if (response < 0)' check and, as a result,
the code says "Cancelled".
This fixes https://savannah.gnu.org/bugs/?56023.
Reported-by: Devin Hussey <husseydevin@gmail.com>
Bug existed since version 4.0, commit 0f9d60a3.
Signed-off-by: Devin Hussey <husseydevin@gmail.com>
When nano was configured with --enable-tiny --enable-speller, the
block_sigwinch() function should be available, to mask SIGWINCHes
during a spell check.
The blocking is needed only during the wait(), so unblock SIGWINCH
again right after the wait() -- also to have the unblocking before
a possible error exit.
Somehow a SIGWINCH pushes nano past the wait() in do_alt_speller(),
even though the external spelling program hasn't finished.
This fixes https://savannah.gnu.org/bugs/?56010
by reverting commit 1f39f60b.
Bug existed since version 3.2.
Also because most of nano has meanwhile been written by other people
than Chris. And because authorship is meta-information, irrelevant
for knowing how to operate nano.
Since commit 4c6ec637 from about half a year ago, the 'action' parameter
of update_undo() is unused. Verify that this parameter matches the type
of the item at the top of the undo stack, so that in another half year
the parameter can be safely removed.
Determine the actual number of bytes the striped character consists of,
instead of assuming it's simply one, and determine the real column that
the character starts in, instead of assuming it's the stripe column.
This fixes https://savannah.gnu.org/bugs/?55917
and fixes https://savannah.gnu.org/bugs/?55922.
Condensed-by: Benno Schulenberg <bensberg@telfort.nl>
When the mark is off, initialize not just 'bot_x' but also 'top_x'.
This fixes https://savannah.gnu.org/bugs/?55898.
Bug existed since the justifying of a marked region was introduced,
four days ago, with commit f7f5514e.
When there is a dash among the files on the command line, nano will read
data from standard input, which means that the latter is not connected to
a terminal and thus cannot be recognized as a Linux VT until nano has
finished reading the input and has reconnected the input source to the
terminal.
The first probe for a Linux VT is kept in place for now, so that nano
can stop when there are errors in an rcfile while running on a VT.
(This stopping will not work when data is read from standard input,
of course, but that is a smaller fish.)
This fixes https://savannah.gnu.org/bugs/?55912.
Reported-by: Enrico Mioso <mrkiko.rs@gmail.com>
Bug existed since the recognition of modified cursor keys on a Linux
console was introduced, in version 2.6.3, commit 290d278f.