summaryrefslogtreecommitdiff
path: root/source3/client/client.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/client/client.c')
-rw-r--r--source3/client/client.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/source3/client/client.c b/source3/client/client.c
index 1d42fd2995..886af863e4 100644
--- a/source3/client/client.c
+++ b/source3/client/client.c
@@ -1336,15 +1336,15 @@ static struct file_list {
Free a file_list structure.
****************************************************************************/
-static void free_file_list (struct file_list * list)
+static void free_file_list (struct file_list *list_head)
{
- struct file_list *tmp;
+ struct file_list *list, *next;
- while (list) {
- tmp = list;
- DLIST_REMOVE(list, list);
- SAFE_FREE(tmp->file_path);
- SAFE_FREE(tmp);
+ for (list = list_head; list; list = next) {
+ next = list->next;
+ DLIST_REMOVE(list_head, list);
+ SAFE_FREE(list->file_path);
+ SAFE_FREE(list);
}
}