svn commit: samba r14359 - in branches/SAMBA_3_0/source/client: .
jra at samba.org
jra at samba.org
Mon Mar 13 23:58:59 GMT 2006
Author: jra
Date: 2006-03-13 23:58:58 +0000 (Mon, 13 Mar 2006)
New Revision: 14359
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=14359
Log:
Try and fix Coverity #176 by making the pointer
aliasing clearer. This isn't a bug but a code
clarification.
Jeremy.
Modified:
branches/SAMBA_3_0/source/client/client.c
Changeset:
Modified: branches/SAMBA_3_0/source/client/client.c
===================================================================
--- branches/SAMBA_3_0/source/client/client.c 2006-03-13 23:56:08 UTC (rev 14358)
+++ branches/SAMBA_3_0/source/client/client.c 2006-03-13 23:58:58 UTC (rev 14359)
@@ -1336,15 +1336,15 @@
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);
}
}
More information about the samba-cvs
mailing list