afs: Fix memory leak in make_status_items().
authorAndre Noll <maan@tuebingen.mpg.de>
Tue, 2 Jan 2018 23:55:03 +0000 (00:55 +0100)
committerAndre Noll <maan@tuebingen.mpg.de>
Tue, 13 Mar 2018 02:28:10 +0000 (03:28 +0100)
commit835ae89b10977f42fc509addce93bb83af8f6ba4
tree7608419f0af33a5adf1d4c58f83ee7dd38a25184
parentc2ded8b6ba39c639a3d7ff2f4f21a6fa22ef96a9
afs: Fix memory leak in make_status_items().

The leak occurs when the second call to print_list_item() fails. In
this case we leak the memory pointed to by the lpr pointer. This patch
also streamlines the code a bit by introducing the free_status_items()
helper.
aft.c