diff options
author | Felipe Oliveira Carvalho <felipekde@gmail.com> | 2014-04-04 14:24:13 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2014-04-11 12:57:59 -0300 |
commit | 86279cefae74ead8c740575d294ef06e12aa7da8 (patch) | |
tree | b0be9f06cb3aec89629c8ab8bb60a6cddce010ae /src/edit.c | |
parent | 3fcdb2ab29f6285b4b5b4fd706db54a98b1a773f (diff) | |
download | rneovim-86279cefae74ead8c740575d294ef06e12aa7da8.tar.gz rneovim-86279cefae74ead8c740575d294ef06e12aa7da8.tar.bz2 rneovim-86279cefae74ead8c740575d294ef06e12aa7da8.zip |
Remove more OOM error handling code
From the functions:
- ExpandBufnames
- buf_modname()
- do_autocmd_event()
- ff_create_stack_element()
- ff_get_visited_list()
- ins_complete()
- msg_show_console_dialog()
- prt_find_resource()
- vim_findfile_init()
TODO: refactor msg_show_console_dialog() to make sure it doesn't ever return
NULL.
Diffstat (limited to 'src/edit.c')
-rw-r--r-- | src/edit.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/edit.c b/src/edit.c index fb60fb25c1..acb05f6588 100644 --- a/src/edit.c +++ b/src/edit.c @@ -4345,8 +4345,6 @@ static int ins_complete(int c) /* we need up to 2 extra chars for the prefix */ compl_pattern = alloc(quote_meta(NULL, line + compl_col, compl_length) + 2); - if (compl_pattern == NULL) - return FAIL; if (!vim_iswordp(line + compl_col) || (compl_col > 0 && ( @@ -4392,16 +4390,12 @@ static int ins_complete(int c) * alloc(7) is enough -- Acevedo */ compl_pattern = alloc(7); - if (compl_pattern == NULL) - return FAIL; STRCPY((char *)compl_pattern, "\\<"); (void)quote_meta(compl_pattern + 2, line + compl_col, 1); STRCAT((char *)compl_pattern, "\\k"); } else { compl_pattern = alloc(quote_meta(NULL, line + compl_col, compl_length) + 2); - if (compl_pattern == NULL) - return FAIL; STRCPY((char *)compl_pattern, "\\<"); (void)quote_meta(compl_pattern + 2, line + compl_col, compl_length); |