[UDP-HTTP] Improve free_results_list()
This commit is contained in:
parent
46e295dc09
commit
3a38d2bc1e
|
@ -496,11 +496,14 @@ void realloc_answer(size_t new_size)
|
||||||
*/
|
*/
|
||||||
void free_results_list()
|
void free_results_list()
|
||||||
{
|
{
|
||||||
results_list *ptr = results ;
|
while (results != NULL)
|
||||||
while (ptr != NULL)
|
|
||||||
{
|
{
|
||||||
owl_free_result(ptr->result) ;
|
owl_free_result(results->result) ;
|
||||||
ptr = ptr->next ;
|
results = results->next ;
|
||||||
|
#ifndef NDEBUG
|
||||||
|
--nb_results ;
|
||||||
|
#endif // NDEBUG
|
||||||
}
|
}
|
||||||
|
assert(nb_results == 0) ;
|
||||||
nb_results = 0 ;
|
nb_results = 0 ;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue