Prevent self referencing next pointer during insert.

oldstable
Ulrich Czekalla 1999-10-13 12:26:37 +00:00 committed by Alexandre Julliard
parent febd2db82e
commit c87736df1f
1 changed files with 1 additions and 0 deletions

View File

@ -1721,6 +1721,7 @@ TREEVIEW_InsertItemA (HWND hwnd, WPARAM wParam, LPARAM lParam)
switch ((DWORD) ptdi->hInsertAfter) {
case (DWORD) TVI_FIRST:
if (sibItem==wineItem) break;
if (wineItem->parent) {
wineItem->sibling=parentItem->firstChild;
parentItem->firstChild=(HTREEITEM)iItem;