diff options
| author | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2023-03-04 02:06:19 +0100 |
|---|---|---|
| committer | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2023-07-20 23:52:51 +0200 |
| commit | 67ffb772b7488b84e37e6880290820fc54434b33 (patch) | |
| tree | 574f95ad5834282261846daede1f653b1d1d0666 /doc/man3/html_node_alloc.3 | |
| parent | 37fd5c92aebd87af14a1f73f8e567b8b74f6bd36 (diff) | |
| download | libweb-67ffb772b7488b84e37e6880290820fc54434b33.tar.gz | |
Fix memory leak on failed realloc(3)
According to C99 ยง7.20.3.4:
If memory for the new object cannot be allocated, the old object is not
deallocated and its value is unchanged.
Therefore, a temporary pointer must be used to ensure the original
object can still be deallocated should realloc(3) return a null pointer.
Diffstat (limited to 'doc/man3/html_node_alloc.3')
0 files changed, 0 insertions, 0 deletions
