DXGL r785 - Code Review
For
DXGL
(
recent comments
|
status changes
|
tags
|
authors
|
states
|
release notes
|
statistics
)
Jump to navigation
Jump to search
Repository:
DXGL
Revision:
<
r784
|
r785
|
r786
>
Date:
03:33, 24 February 2018
Author:
admin
Status:
new
Tags:
Comment:
Fix application profile registry path.
Modified paths:
/cfgmgr/cfgmgr.c
(modified) (
history
)
Diff
[
purge
]
Index: cfgmgr/cfgmgr.c
—
—
@@ -1104,17 +1104,18 @@
1105
1105
TCHAR sha256string[65];
1106
1106
FILE *file;
1107
1107
TCHAR filename[MAX_PATH+1];
1108
+ TCHAR regkey[MAX_PATH + 80];
1108
1109
int i;
1109
1110
BOOL DPIAwarePM = FALSE;
1110
1111
HMODULE hSHCore = NULL;
1111
1112
HMODULE hUser32 = NULL;
1112
1113
GetModuleFileName(NULL, filename, MAX_PATH);
1113
- _tcscpy(cfg->regkey, regkeybase);
1114
- _tcscat(cfg->regkey, _T("Profiles\\"));
1114
+ _tcscpy(regkey, regkeybase);
1115
+ _tcscat(regkey, _T("Profiles\\"));
1115
1116
for (i = _tcslen(filename); (i > 0) && (filename[i] != 92) && (filename[i] != 47); i--);
1116
1117
i++;
1117
- _tcscat(cfg->regkey, &filename[i]);
1118
- _tcscat(cfg->regkey, _T("-"));
1118
+ _tcscat(regkey, &filename[i]);
1119
+ _tcscat(regkey, _T("-"));
1119
1120
i--;
1120
1121
filename[i] = 0;
1121
1122
_tcslwr(filename);
—
—
@@ -1127,8 +1128,9 @@
1128
1129
sha256string[(i * 2) + 1] = (TCHAR)hexdigit(sha256.bytes[i] & 0xF);
1129
1130
}
1130
1131
sha256string[256 / 4] = 0;
1131
- _tcscat(cfg->regkey, sha256string);
1132
+ _tcscat(regkey, sha256string);
1132
1133
GetGlobalConfig(cfg, initial);
1134
+ _tcscpy(cfg->regkey, regkey);
1133
1135
ReadINI(cfg);
1134
1136
if (cfg->OverrideDefaults)
1135
1137
{
Navigation menu
Personal tools
Log in
Namespaces
Special page
English
expanded
collapsed
Views
More
expanded
collapsed
Search
Navigation
Home
Main page
Recent changes
Random page
MediaWiki help
Introduction
Progress
Downloads
Source code
Build from source
AppDB
Bug reports
Forums
Tools
Special pages
Printable version