From 321a65bdc34d2dbf9adfab198d58a9910975879f Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Tue, 8 Oct 2019 20:00:26 -0500 Subject: hscript: Fix the first bug found by automated testing Don't try to use a value of a key that has no value --- hscript/script.cc | 1 + 1 file changed, 1 insertion(+) (limited to 'hscript') diff --git a/hscript/script.cc b/hscript/script.cc index 8c0c380..1bb2176 100644 --- a/hscript/script.cc +++ b/hscript/script.cc @@ -187,6 +187,7 @@ const Script *Script::load(std::istream &sstream, const ScriptOptions opts) { if(key_end == std::string::npos || value_begin == std::string::npos) { /* Key without value */ PARSER_ERROR("key '" + key + "' has no value") + continue; } /* Normalise key to lower-case */ -- cgit v1.2.3-70-g09d2