From 3e16f4c814816d1d9641700a1c7ffd9e2158afc9 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Mon, 30 May 2022 22:19:03 +0300 Subject: Autocommit at 30.05.2022 @ 22:19 --- src/Models/Table.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/Models/Table.cpp') diff --git a/src/Models/Table.cpp b/src/Models/Table.cpp index 4692a9e..5e7f2a9 100644 --- a/src/Models/Table.cpp +++ b/src/Models/Table.cpp @@ -91,13 +91,15 @@ void Table::readFromFile(std::ifstream& inFile) { else if (inFile.peek() == '"') { String res; inFile.get(); + char buffer; while (inFile.peek() != '"') { if (inFile.peek() == '\n') throw std::logic_error(fileLocationExceptionMsg("Error: Could not find a matching end quote for string at row ", cells.get_count(), inFile.tellg() % cols + 1)); if (inFile.peek() == '\\') { inFile.get(); } - res += inFile.get(); + buffer = inFile.get(); + res += (const char*)&buffer; } inFile.get(); -- cgit v1.3.1-23-gd82d