Francois Gouget : comctl32: Avoid an unneeded lstrlenW() call.

Alexandre Julliard julliard at winehq.org
Mon Oct 22 15:38:44 CDT 2018


Module: wine
Branch: master
Commit: ab9dccda63f3bfa02e6a9e87dfc2eff4a346cd12
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=ab9dccda63f3bfa02e6a9e87dfc2eff4a346cd12

Author: Francois Gouget <fgouget at free.fr>
Date:   Mon Oct 22 03:16:56 2018 +0200

comctl32: Avoid an unneeded lstrlenW() call.

Signed-off-by: Francois Gouget <fgouget at free.fr>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/comctl32/toolbar.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/comctl32/toolbar.c b/dlls/comctl32/toolbar.c
index 6a51ad7..ec3b498 100644
--- a/dlls/comctl32/toolbar.c
+++ b/dlls/comctl32/toolbar.c
@@ -2435,7 +2435,7 @@ TOOLBAR_CustomizeDialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
                     btnInfo->btn = nmtb.tbButton;
                     if (!(nmtb.tbButton.fsStyle & BTNS_SEP))
                     {
-                        if (lstrlenW(nmtb.pszText))
+                        if (*nmtb.pszText)
                             lstrcpyW(btnInfo->text, nmtb.pszText);
                         else if (nmtb.tbButton.iString >= 0 && 
                             nmtb.tbButton.iString < infoPtr->nNumStrings)




More information about the wine-cvs mailing list