mirror of
https://github.com/neovim/neovim.git
synced 2025-09-29 06:28:35 +00:00
Replace vim_free() implementation
This replaces the vim_free() implementation with a free() call and adds a deprecated flag for the doxygen documentation.
This commit is contained in:

committed by
Justin M. Keyes

parent
e42a3cc4e6
commit
c5cac800e7
12
src/misc2.c
12
src/misc2.c
@@ -634,17 +634,15 @@ int copy_option_part(char_u **option, char_u *buf, int maxlen, char *sep_chars)
|
|||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
///
|
||||||
* Replacement for free() that ignores NULL pointers.
|
/// Replacement for free().
|
||||||
* Also skip free() when exiting for sure, this helps when we caught a deadly
|
///
|
||||||
* signal that was caused by a crash in free().
|
/// @deprecated Use free() instead
|
||||||
*/
|
///
|
||||||
void vim_free(void *x)
|
void vim_free(void *x)
|
||||||
{
|
{
|
||||||
if (x != NULL && !really_exiting) {
|
|
||||||
free(x);
|
free(x);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Return the current end-of-line type: EOL_DOS, EOL_UNIX or EOL_MAC.
|
* Return the current end-of-line type: EOL_DOS, EOL_UNIX or EOL_MAC.
|
||||||
|
Reference in New Issue
Block a user