dlls/include/list.h: remove_list() failed when removing first or last element

Robert Shearman rob at codeweavers.com
Wed Nov 9 13:03:34 CST 2005


Markus Gömmel wrote:

>Sometimes resulted in an exception when AllocHeap() was called...
>
>Regards
>
>Markus Goemmel
>m.goemmel at compulab.de
>  
>

Sorry, but the patch is wrong. The Wine list implementation makes sure 
that next and prev are always valid pointers, such that the list is 
circular. The only way to detect the end of the list is if entry->next 
== start. If one of the entries is NULL then this generally indicates 
either a use after free or some other kind of corruption of the memory 
used by the list. If the memory is in the heap then HeapValidate may 
help find the corruption.

>Index: ChangeLog
>===================================================================
>RCS file: /home/wine/wine/ChangeLog,v
>retrieving revision 1.101
>diff -u -u -p -r1.101 ChangeLog
>--- ChangeLog	9 Nov 2005 13:41:27 -0000	1.101
>+++ ChangeLog	9 Nov 2005 16:17:58 -0000
>@@ -1,3 +1,8 @@
>+2005-11-09  Markus Goemmel <m.goemmel at compulab.de>
>+
>+	* include/wine/list.h
>+	list_remove() failed when removing first or last element
>+
> 2005-11-09  Huw Davies <huw at codeweavers.com>
> 
> 	* dlls/wineps/ps.c:
>  
>

One further note: on projects as big as Wine patching the ChangeLog is 
not practical as it would result in a lot of conflicts. Therefore, 
Alexandre Julliard automatically generates ChangeLog entries from CVS 
just before each release.

-- 
Rob Shearman




More information about the wine-devel mailing list