Unverified Commit c2793a36 authored by Chen's avatar Chen Committed by GitHub
Browse files

Fix runtime exceptions in Visual Studio environment. (#926)

parent bc9874c9
...@@ -48,7 +48,7 @@ void SingleDocParser::HandleDocument(EventHandler& eventHandler) { ...@@ -48,7 +48,7 @@ void SingleDocParser::HandleDocument(EventHandler& eventHandler) {
} }
void SingleDocParser::HandleNode(EventHandler& eventHandler) { void SingleDocParser::HandleNode(EventHandler& eventHandler) {
DepthGuard<2000> depthguard(depth, m_scanner.mark(), ErrorMsg::BAD_FILE); DepthGuard<500> depthguard(depth, m_scanner.mark(), ErrorMsg::BAD_FILE);
// an empty node *is* a possibility // an empty node *is* a possibility
if (m_scanner.empty()) { if (m_scanner.empty()) {
......
...@@ -804,7 +804,7 @@ TEST_F(EmitterTest, OutputCharset) { ...@@ -804,7 +804,7 @@ TEST_F(EmitterTest, OutputCharset) {
out << "\x24 \xC2\xA2 \xE2\x82\xAC"; out << "\x24 \xC2\xA2 \xE2\x82\xAC";
out << EndSeq; out << EndSeq;
ExpectEmit("- $ ¢ €\n- \"$ \\xa2 \\u20ac\""); ExpectEmit("- \x24 \xC2\xA2 \xE2\x82\xAC\n- \"\x24 \\xa2 \\u20ac\"");
} }
TEST_F(EmitterTest, EscapedUnicode) { TEST_F(EmitterTest, EscapedUnicode) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment