[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()
|
||||
{
|
||||
results_list *ptr = results ;
|
||||
while (ptr != NULL)
|
||||
while (results != NULL)
|
||||
{
|
||||
owl_free_result(ptr->result) ;
|
||||
ptr = ptr->next ;
|
||||
owl_free_result(results->result) ;
|
||||
results = results->next ;
|
||||
#ifndef NDEBUG
|
||||
--nb_results ;
|
||||
#endif // NDEBUG
|
||||
}
|
||||
assert(nb_results == 0) ;
|
||||
nb_results = 0 ;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue