Commit 8b55e4a6 authored by Rein Klazes's avatar Rein Klazes Committed by Alexandre Julliard

comctl32: Do not free LPSTR_TEXTCALLBACK tooltip texts.

parent 213cee62
......@@ -2025,7 +2025,8 @@ TOOLTIPS_SetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam)
else {
if ( (toolPtr->lpszText) &&
!IS_INTRESOURCE(toolPtr->lpszText) ) {
Free (toolPtr->lpszText);
if( toolPtr->lpszText != LPSTR_TEXTCALLBACKW)
Free (toolPtr->lpszText);
toolPtr->lpszText = NULL;
}
if (lpToolInfo->lpszText) {
......@@ -2082,7 +2083,8 @@ TOOLTIPS_SetToolInfoW (HWND hwnd, WPARAM wParam, LPARAM lParam)
else {
if ( (toolPtr->lpszText) &&
!IS_INTRESOURCE(toolPtr->lpszText) ) {
Free (toolPtr->lpszText);
if( toolPtr->lpszText != LPSTR_TEXTCALLBACKW)
Free (toolPtr->lpszText);
toolPtr->lpszText = NULL;
}
if (lpToolInfo->lpszText) {
......@@ -2208,7 +2210,8 @@ TOOLTIPS_UpdateTipTextA (HWND hwnd, WPARAM wParam, LPARAM lParam)
else {
if ( (toolPtr->lpszText) &&
!IS_INTRESOURCE(toolPtr->lpszText) ) {
Free (toolPtr->lpszText);
if( toolPtr->lpszText != LPSTR_TEXTCALLBACKW)
Free (toolPtr->lpszText);
toolPtr->lpszText = NULL;
}
if (lpToolInfo->lpszText) {
......@@ -2265,7 +2268,8 @@ TOOLTIPS_UpdateTipTextW (HWND hwnd, WPARAM wParam, LPARAM lParam)
else {
if ( (toolPtr->lpszText) &&
!IS_INTRESOURCE(toolPtr->lpszText) ) {
Free (toolPtr->lpszText);
if( toolPtr->lpszText != LPSTR_TEXTCALLBACKW)
Free (toolPtr->lpszText);
toolPtr->lpszText = NULL;
}
if (lpToolInfo->lpszText) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment