mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-27 01:28:46 +00:00
* readline.c (rl_read_init_file): Make sure that null filename is
not passed to open() or else we end up opening the directory, and read a bunch of garbage into keymap[].
This commit is contained in:
@@ -5484,6 +5484,9 @@ rl_read_init_file (filename)
|
||||
|
||||
openname = tilde_expand (filename);
|
||||
|
||||
if (!openname || *openname == '\000')
|
||||
return ENOENT;
|
||||
|
||||
if ((stat (openname, &finfo) < 0) ||
|
||||
(file = open (openname, O_RDONLY, 0666)) < 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user