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

github.com/miloyip/rapidjson.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'include/rapidjson/filereadstream.h')
-rw-r--r--include/rapidjson/filereadstream.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/rapidjson/filereadstream.h b/include/rapidjson/filereadstream.h
index f1bfb7d0..6b343707 100644
--- a/include/rapidjson/filereadstream.h
+++ b/include/rapidjson/filereadstream.h
@@ -59,7 +59,7 @@ public:
// For encoding detection only.
const Ch* Peek4() const {
- return (current_ + 4 <= bufferLast_) ? current_ : 0;
+ return (current_ + 4 - !eof_ <= bufferLast_) ? current_ : 0;
}
private: