On Mon, Jul 13, 2026 at 11:30:29PM -0500, Sami Imseih wrote: > When an error is returned from a callback, the error block in 0002 only > discards the core stats temp file and then moves on to call the finish > callback for every extension that registered one ( and they better register > one to perform cleanups ). So, the proposed will not cause any missed > cleanups of auxiliary files.
Really? How do you make sure that an error is detected if you are dealing with multiple stats kinds where each one of them have their own set of auxiliary files to write to, say: - 2 custom stats kinds, each one uses one auxiliary file. - Write of the stats at shutdown. - Suddenly kind 1 fails, returns a status. Its auxiliary file is removable due to the ferror(), the main stats file is also discarded. Kind 2 may not have the opportunity to mark its file as problematic, meaning that it would be skipped at finish(STATS_WRITE) and left around, especially if we are dealing with the most common scenarios of an ENOSPC or an EROFS with all these files written on the same partition, most likely the one of the root data folder. -- Michael
signature.asc
Description: PGP signature
