mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-25 22:29:42 +03:00
in the low-level input routines, make the ascii_digits variables ints
instead of size_t's, since they will only hold very small values git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2136 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
This commit is contained in:
parent
12642edfc9
commit
698263ca5c
@ -51,6 +51,11 @@ CVS code -
|
||||
do_justify()
|
||||
- For consistency, preserve placewewant if we didn't unjustify
|
||||
instead of setting it to 0. (DLR)
|
||||
- winio.c:
|
||||
get_kbinput(), get_translated_kbinput(), get_ascii_kbinput(),
|
||||
get_untranslated_kbinput()
|
||||
- Make the ascii_digits variables ints instead of size_t's,
|
||||
since they will only hold very small values. (DLR)
|
||||
|
||||
GNU nano 1.3.5 - 2004.11.22
|
||||
- General:
|
||||
|
@ -531,7 +531,7 @@ int get_translated_kbinput(int kbinput, seq_type *seq
|
||||
, bool reset
|
||||
#endif
|
||||
);
|
||||
int get_ascii_kbinput(int kbinput, size_t ascii_digits
|
||||
int get_ascii_kbinput(int kbinput, int ascii_digits
|
||||
#ifndef NANO_SMALL
|
||||
, bool reset
|
||||
#endif
|
||||
|
12
src/winio.c
12
src/winio.c
@ -271,7 +271,7 @@ int get_translated_kbinput(int kbinput, seq_type *seq
|
||||
)
|
||||
{
|
||||
static int escapes = 0;
|
||||
static size_t ascii_digits = 0;
|
||||
static int ascii_digits = 0;
|
||||
int retval = ERR;
|
||||
|
||||
#ifndef NANO_SMALL
|
||||
@ -498,7 +498,7 @@ int get_translated_kbinput(int kbinput, seq_type *seq
|
||||
*seq = UTF8_SEQ;
|
||||
|
||||
#ifdef DEBUG
|
||||
fprintf(stderr, "get_translated_kbinput(): kbinput = %d, seq = %d, escapes = %d, ascii_digits = %lu, retval = %d\n", kbinput, (int)*seq, escapes, (unsigned long)ascii_digits, retval);
|
||||
fprintf(stderr, "get_translated_kbinput(): kbinput = %d, seq = %d, escapes = %d, ascii_digits = %d, retval = %d\n", kbinput, (int)*seq, escapes, ascii_digits, retval);
|
||||
#endif
|
||||
|
||||
/* Return the result. */
|
||||
@ -507,7 +507,7 @@ int get_translated_kbinput(int kbinput, seq_type *seq
|
||||
|
||||
/* Translate an ASCII character sequence: turn a three-digit decimal
|
||||
* ASCII code from 000-255 into its corresponding ASCII character. */
|
||||
int get_ascii_kbinput(int kbinput, size_t ascii_digits
|
||||
int get_ascii_kbinput(int kbinput, int ascii_digits
|
||||
#ifndef NANO_SMALL
|
||||
, bool reset
|
||||
#endif
|
||||
@ -594,7 +594,7 @@ int get_ascii_kbinput(int kbinput, size_t ascii_digits
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
fprintf(stderr, "get_ascii_kbinput(): kbinput = %d, ascii_digits = %lu, ascii_kbinput = %d, retval = %d\n", kbinput, (unsigned long)ascii_digits, ascii_kbinput, retval);
|
||||
fprintf(stderr, "get_ascii_kbinput(): kbinput = %d, ascii_digits = %d, ascii_kbinput = %d, retval = %d\n", kbinput, ascii_digits, ascii_kbinput, retval);
|
||||
#endif
|
||||
|
||||
/* If the result is an ASCII character, reset the ASCII character
|
||||
@ -1290,7 +1290,7 @@ int get_untranslated_kbinput(int kbinput, size_t position, bool
|
||||
#endif
|
||||
)
|
||||
{
|
||||
static size_t ascii_digits = 0;
|
||||
static int ascii_digits = 0;
|
||||
int retval;
|
||||
|
||||
#ifndef NANO_SMALL
|
||||
@ -1337,7 +1337,7 @@ int get_untranslated_kbinput(int kbinput, size_t position, bool
|
||||
retval = kbinput;
|
||||
|
||||
#ifdef DEBUG
|
||||
fprintf(stderr, "get_untranslated_kbinput(): kbinput = %d, position = %lu, ascii_digits = %lu\n", kbinput, (unsigned long)position, (unsigned long)ascii_digits);
|
||||
fprintf(stderr, "get_untranslated_kbinput(): kbinput = %d, position = %lu, ascii_digits = %d\n", kbinput, (unsigned long)position, ascii_digits);
|
||||
#endif
|
||||
|
||||
return retval;
|
||||
|
Loading…
Reference in New Issue
Block a user