Append new lines to the lineinput string instead of doing concatenation in filefuncs.cpp

This commit is contained in:
Username404 2021-09-29 18:32:36 +02:00
parent f227182713
commit 54aa4105b8
Signed by: Username404-59
GPG Key ID: 7AB361FBB257A5D1
1 changed files with 1 additions and 1 deletions

View File

@ -8,7 +8,7 @@ string getFileContent(const string& file)
string lineinput, fullinput;
fileStream.open(file, ios::in);
if (fileStream.is_open()) while (getline(fileStream, lineinput)) {
fullinput.append(lineinput + "\n");
fullinput.append(lineinput += '\n');
} else throw Yerbacon::Exception("Could not open \"" + file + "\".");
fileStream.close();
return fullinput;