Skip to content

Commit

Permalink
Fixed an issue where LoadCode only loaded length of the file path rat…
Browse files Browse the repository at this point in the history
…her than the size of the StringBuilder capacity.
  • Loading branch information
hollow87 committed Mar 8, 2018
1 parent 29bc3fa commit 9bb4133
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Memory/Class1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ public string LoadCode(string name, string file)
uint read_ini_result;

if (file != "")
read_ini_result = GetPrivateProfileString("codes", name, "", returnCode, (uint)file.Length, file);
read_ini_result = GetPrivateProfileString("codes", name, "", returnCode, (uint)returnCode.Capacity, file);
else
returnCode.Append(name);

Expand Down

0 comments on commit 9bb4133

Please sign in to comment.