summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2013-08-19 06:27:36 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2013-08-19 06:27:36 +0000
commitafcae1ce5031538870997cf0f4224185557ea49d (patch)
tree1293414751727a0c4d3afc2d0d77a1a93effc63c /plugins
parent6897c90c6003af7b21d271771320999ddfe2d09a (diff)
- VersionInfo - fix for IE detect
- CrashDumper - Correct SIZEOF (patch from person) git-svn-id: http://svn.miranda-ng.org/main/trunk@5740 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/CrashDumper/src/utils.cpp6
-rw-r--r--plugins/VersionInfo/src/utils.cpp9
2 files changed, 9 insertions, 6 deletions
diff --git a/plugins/CrashDumper/src/utils.cpp b/plugins/CrashDumper/src/utils.cpp
index 6bbb81c2c8..a00e25317c 100644
--- a/plugins/CrashDumper/src/utils.cpp
+++ b/plugins/CrashDumper/src/utils.cpp
@@ -383,15 +383,15 @@ void GetInternetExplorerVersion(bkstring& buffer)
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, TEXT("SOFTWARE\\Microsoft\\Internet Explorer"), 0,
KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
{
- size = sizeof(ieBuild)/sizeof(ieBuild[0]);
+ SIZEOF(ieBuild);
if (RegQueryValueEx(hKey, TEXT("Build"), NULL, NULL, (LPBYTE) ieBuild, &size) != ERROR_SUCCESS)
ieBuild[0] = 0;
- size = sizeof(ieVersion)/sizeof(ieVersion[0]);
+ size = SIZEOF(ieVersion);
if (RegQueryValueEx(hKey, TEXT("Version"), NULL, NULL, (LPBYTE) ieVersion, &size) != ERROR_SUCCESS)
ieVersion[0] = 0;
- size = sizeof(iVer)/sizeof(iVer[0]);
+ size = SIZEOF(iVer);
if (RegQueryValueEx(hKey, TEXT("IVer"), NULL, NULL, (LPBYTE) iVer, &size) != ERROR_SUCCESS)
iVer[0] = 0;
diff --git a/plugins/VersionInfo/src/utils.cpp b/plugins/VersionInfo/src/utils.cpp
index 718dbd8881..9c2123239a 100644
--- a/plugins/VersionInfo/src/utils.cpp
+++ b/plugins/VersionInfo/src/utils.cpp
@@ -363,11 +363,14 @@ BOOL GetInternetExplorerVersion(TCHAR *ieVersion, size_t ieSize)
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("SOFTWARE\\Microsoft\\Internet Explorer"), 0, KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
{
DWORD size;
- if (RegQueryValueEx(hKey, _T("Version"), NULL, NULL, (LPBYTE) ieVer, &size) != ERROR_SUCCESS)
+ size = SIZEOF(ieVer);
+ if (RegQueryValueEx(hKey, TEXT("Version"), NULL, NULL, (LPBYTE) ieVer, &size) != ERROR_SUCCESS)
ieVer[0] = 0;
- if (RegQueryValueEx(hKey, _T("Build"), NULL, NULL, (LPBYTE) ieBuild, &size) != ERROR_SUCCESS)
+ size = SIZEOF(ieBuild);
+ if (RegQueryValueEx(hKey, TEXT("Build"), NULL, NULL, (LPBYTE) ieBuild, &size) != ERROR_SUCCESS)
ieBuild[0] = 0;
- if (RegQueryValueEx(hKey, _T("IVer"), NULL, NULL, (LPBYTE) iVer, &size) != ERROR_SUCCESS)
+ size = SIZEOF(iVer);
+ if (RegQueryValueEx(hKey, TEXT("IVer"), NULL, NULL, (LPBYTE) iVer, &size) != ERROR_SUCCESS)
iVer[0] = 0;
RegCloseKey(hKey);