Allowing only control sequences in the proper range to be rebound.
This fixes Savannah bug #47025. git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5625 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Этот коммит содержится в:
родитель
d83bd7e305
Коммит
14d1b3bd36
@ -3,6 +3,8 @@
|
|||||||
continuing after a discard. This fixes Savannah bug #47104.
|
continuing after a discard. This fixes Savannah bug #47104.
|
||||||
* src/files.c (get_full_path): Plug a sneaky memory leak. This fixes
|
* src/files.c (get_full_path): Plug a sneaky memory leak. This fixes
|
||||||
Savannah bug #47003 reported and solved by Mike Frysinger.
|
Savannah bug #47003 reported and solved by Mike Frysinger.
|
||||||
|
* src/rcfile.c (parse_binding): Allow only control sequences in the
|
||||||
|
proper range to be rebound. This fixes Savannah bug #47025.
|
||||||
|
|
||||||
2016-02-09 Benno Schulenberg <bensberg@justemail.net>
|
2016-02-09 Benno Schulenberg <bensberg@justemail.net>
|
||||||
* src/files.c (stat_with_alloc, open_buffer, write_file): Check the
|
* src/files.c (stat_with_alloc, open_buffer, write_file): Check the
|
||||||
|
@ -452,6 +452,9 @@ void parse_binding(char *ptr, bool dobind)
|
|||||||
else if (keycopy[0] != '^' && keycopy[0] != 'M' && keycopy[0] != 'F') {
|
else if (keycopy[0] != '^' && keycopy[0] != 'M' && keycopy[0] != 'F') {
|
||||||
rcfile_error(N_("Key name must begin with \"^\", \"M\", or \"F\""));
|
rcfile_error(N_("Key name must begin with \"^\", \"M\", or \"F\""));
|
||||||
goto free_copy;
|
goto free_copy;
|
||||||
|
} else if (keycopy[0] == '^' && (keycopy[1] < 64 || keycopy[1] > 127)) {
|
||||||
|
rcfile_error(N_("Key name %s is invalid"), keycopy);
|
||||||
|
goto free_copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dobind) {
|
if (dobind) {
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user