From b9081f24720ba8fc609fecd15b444d659be4338f Mon Sep 17 00:00:00 2001
From: Akash Mozumdar <akashmozumdar@gmail.com>
Date: Sat, 7 Mar 2020 03:45:07 -0700
Subject: [PATCH] fix large file being read wrong

---
 extensions/blockmarkup.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/extensions/blockmarkup.h b/extensions/blockmarkup.h
index 905f2ff..05eb77a 100644
--- a/extensions/blockmarkup.h
+++ b/extensions/blockmarkup.h
@@ -40,7 +40,7 @@ private:
 			}
 			int oldSize = buffer.size();
 			buffer.resize(oldSize + blockSize);
-			if (!streambuf.sgetn((char*)buffer.data() + oldSize, blockSize * sizeof(C))) return {};
+			if (!streambuf.sgetn((char*)(buffer.data() + oldSize), blockSize * sizeof(C))) return {};
 			i = max(0, oldSize - (int)delimiter.size());
 			if (discard)
 			{