Thomas Weidenmueller wrote:
Reduce memory usage of the syslink control and fix dependent code.
Alexandre has already said what he doesn't like about the patch, but
I'll be a bit more specific. Put the below changes into a separate patch
plus the moving around of the LIF_STATE case in SYSLI
Thomas Weidenmueller <[EMAIL PROTECTED]> writes:
> @@ -1062,35 +1063,41 @@
>
> if(Item->mask & LIF_ITEMID)
> {
> -if(!di->u.Link.szID)
> +if(di->u.Link.szID)
> {
> -di->u.Link.szID = Alloc((MAX_LINKID_TEXT + 1) * sizeof(WCHAR));
> -if(!I
Thomas Weidenmueller <[EMAIL PROTECTED]> writes:
> Reduce memory usage of the syslink control.
>
> Please let me know if there's something wrong with this patch.
There are many unrelated changes in there. Please send separate
changes as separate patches.
--
Alexandre Julliard
[EMAIL PROTECTED]
Thomas Weidenmueller wrote:
@@ -135,16 +141,16 @@
SL_ITEM_TYPE type, PDOC_ITEM LastItem)
{
PDOC_ITEM Item;
-Item = Alloc(sizeof(DOC_ITEM) + ((textlen + 1) * sizeof(WCHAR)));
+
+textlen = min(textlen, lstrlenW(Text));
+Item = Alloc(FIELD_OFF