Ilya, Am 26.01.20 um 19:06 schrieb Илья Шипицин: > such things are fragile. once fixed, they can silently break during > further refactoring.
The function is fairly self contained. I don't expect there to be any need for refactoring. Also the previous version was fairly elaborate for a simple task, leading to this bug. > on other hand, such functions are good candidates to write unit tests. William's suggestion is "obviously correct" by code review (and my understanding of the task). While this is a good candidate for unit tests it's also easy to spot mistakes during code review. > maybe we should consider things like cmocka ? > While I obviously can't speak for HAProxy Team: Please not more tools. That just complicates the process for no real gain. We are in a good situation with VTest and Travis / Cirrus / GitHub Actions. Anything else just adds moving parts with diminishing returns. Best regards Tim Düsterhus

