diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2019-10-08 20:00:26 -0500 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2019-10-08 20:00:26 -0500 |
commit | 321a65bdc34d2dbf9adfab198d58a9910975879f (patch) | |
tree | 5c3fb06417885828c3bfe4f10f7edaa76cfb9d57 /hscript | |
parent | 5b0d0916b27f271fc12a8c0c6b595e11673d306d (diff) | |
download | horizon-321a65bdc34d2dbf9adfab198d58a9910975879f.tar.gz horizon-321a65bdc34d2dbf9adfab198d58a9910975879f.tar.bz2 horizon-321a65bdc34d2dbf9adfab198d58a9910975879f.tar.xz horizon-321a65bdc34d2dbf9adfab198d58a9910975879f.zip |
hscript: Fix the first bug found by automated testing
Don't try to use a value of a key that has no value
Diffstat (limited to 'hscript')
-rw-r--r-- | hscript/script.cc | 1 |
1 files changed, 1 insertions, 0 deletions
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 */ |