mirror of
https://github.com/neovim/neovim.git
synced 2025-09-27 21:48:35 +00:00
Remove alloc_clear
Use `xcalloc` instead. Inline `alloc_tv` and `alloc_string_tv` in eval.c
This commit is contained in:

committed by
Thiago de Arruda

parent
c70a526a5d
commit
4e1b364a3e
@@ -53,14 +53,6 @@ char_u *alloc(unsigned size)
|
||||
return lalloc((long_u)size, TRUE);
|
||||
}
|
||||
|
||||
/*
|
||||
* Allocate memory and set all bytes to zero.
|
||||
*/
|
||||
char_u *alloc_clear(unsigned size)
|
||||
{
|
||||
return (char_u *)xcalloc(1, (size_t)size);
|
||||
}
|
||||
|
||||
/// Try to free memory. Used when trying to recover from out of memory errors.
|
||||
/// @see {xmalloc}
|
||||
static void try_to_free_memory()
|
||||
|
Reference in New Issue
Block a user