[LTP] LTP/Lite test float_trigo core dumps due to free(): invalid pointer
linuxtestproject.agent@gmail.com
linuxtestproject.agent@gmail.com
Wed Jul 8 12:21:29 CEST 2026
Hi Tomas,
On Wed, 08 Jul 2026 11:37:15 +0200, Tomas Dzik wrote:
> LTP/Lite test float_trigo core dumps due to free(): invalid pointer
> This fix:
> - initializes pointers where we actually core dumped (*din, *dex).
> - adds checks for all malloc() return values int testcases/misc/math/float/
> directory
> - replaces sprintf() with more secure snprintf() variants
Typo: "int" should be "in".
The commit message lists three distinct changes: initializing the din/dex
pointers in thread_code.c (the crash fix), adding malloc() NULL checks
in the gen*.c files, and replacing sprintf() with snprintf() across 7
files.
These are independently reviewable and deployable changes. The crash fix
is self-contained in thread_code.c. The malloc checks and the
sprintf->snprintf replacements can be bisected and reverted separately.
Please split into separate patches.
Splitting would also let each patch carry a precise subject. The current
subject names float_trigo, but the changes span bessel/, exp_log/,
iperb/, power/, trigo/, thread_code.c, and main.c.
Verdict - Needs revision
---
Note:
The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
More information about the ltp
mailing list