about summary refs log tree commit diff
path: root/stdio-common/tst-printf-fp-free.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix double free in __printf_fp_l (bug 26214).Joseph Myers2020-07-091-0/+37
__printf_fp_l has a double free bug in the case where it allocates memory with malloc internally, then has an I/O error while outputting trailing padding and tries to free that already-freed memory when the error occurs. This patch fixes this by setting the relevant pointer to NULL after the first free (the only free of this pointer that isn't immediately followed by returning from the function). Tested for x86_64 and x86.