Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/simpleini.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'testsi.cpp')
-rw-r--r--testsi.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/testsi.cpp b/testsi.cpp
index 51dca96..609f328 100644
--- a/testsi.cpp
+++ b/testsi.cpp
@@ -154,10 +154,10 @@ TestStreams(
// load the file
CSimpleIni ini(a_bIsUtf8, a_bUseMultiKey, a_bUseMultiLine);
_tprintf(_T("Loading file: %s\n"), a_pszFile);
- std::ifstream infile;
- infile.open(a_pszFile, std::ifstream::in | std::ifstream::binary);
- SI_Error rc = ini.Load(infile);
- infile.close();
+ std::ifstream instream;
+ instream.open(a_pszFile, std::ifstream::in | std::ifstream::binary);
+ SI_Error rc = ini.LoadData(instream);
+ instream.close();
if (rc < 0) {
printf("Failed to open file.\n");
return false;
@@ -167,10 +167,10 @@ TestStreams(
// save the file (simple)
_tprintf(_T("\n-- Saving file to: testsi-out-streams.ini\n"));
- std::ofstream outfile;
- outfile.open("testsi-out-streams.ini", std::ofstream::out | std::ofstream::binary);
- ini.Save(outfile);
- outfile.close();
+ std::ofstream outstream;
+ outstream.open("testsi-out-streams.ini", std::ofstream::out | std::ofstream::binary);
+ ini.Save(outstream);
+ outstream.close();
return true;
}