From 520a495c466793c29f3e721634dfe6cc616b8ede Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 1 May 2014 23:56:03 +0300 Subject: Add missing const. --- src/client.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/client.cpp') diff --git a/src/client.cpp b/src/client.cpp index 83147d34c..78df4e161 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -440,8 +440,7 @@ void Client::gameInit() if (mCurrentServer.hostname.empty()) { - mCurrentServer.hostname = - branding.getValue("defaultServer", "").c_str(); + mCurrentServer.hostname = branding.getValue("defaultServer", ""); mOptions.serverName = mCurrentServer.hostname; } @@ -2996,12 +2995,12 @@ void Client::setIcon() // Attempt to load icon from .ico file HICON icon = (HICON) LoadImage(nullptr, iconFile.c_str(), IMAGE_ICON, 64, 64, LR_LOADFROMFILE); - if (!icon) - logger->log("icon load error"); // If it's failing, we load the default resource file. if (!icon) + { + logger->log("icon load error"); icon = LoadIcon(GetModuleHandle(nullptr), "A"); - + } if (icon) SetClassLong(pInfo.window, GCL_HICON, reinterpret_cast(icon)); #else -- cgit v1.2.3-60-g2f50