Skip to content

Commit a861ea7

Browse files
committed
Fix VS 2008 build
1 parent cee1c39 commit a861ea7

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/io/CompressedInputStream.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,7 @@ void CompressedInputStream::readHeader()
392392
ss << ((w1 == "NONE") ? "" : w1) << ",";
393393
string w2 = TransformFactory<byte>::getName(_transformType);
394394
ss << ((w2 == "NONE") ? "" : w2) << ",";
395-
long fileSize = _ctx.getLong("fileSize", 0);
395+
int64 fileSize = _ctx.getLong("fileSize", 0);
396396
ss << fileSize << ",";
397397

398398
if (szMask != 0) {

src/util/strings.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,8 @@ inline int tokenizeCSV(std::string& s, std::vector<std::string>& tokens, char de
9595
std::stringstream ss;
9696
char prv = 0;
9797

98-
for (auto& c : s) {
99-
if (c == delim) {
98+
for (size_t i =0; i < s.length(); i++) {
99+
if (s[i] == delim) {
100100
if (prv != '\\') {
101101
std::string tk = ss.str();
102102
tokens.push_back(tk);
@@ -106,8 +106,8 @@ inline int tokenizeCSV(std::string& s, std::vector<std::string>& tokens, char de
106106
}
107107
}
108108

109-
ss << c;
110-
prv = c;
109+
ss << s[i];
110+
prv = s[i];
111111
}
112112

113113
std::string tk = ss.str();

0 commit comments

Comments
 (0)