diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2017-01-15 10:45:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-15 10:45:41 +0100 |
commit | 47365e068e4ee121dba825ba7dca6a42e66d724f (patch) | |
tree | ad3dc1bc3e3cac0de01c1a9585449a908d461d06 /core/io/json.cpp | |
parent | 5dde810aa58d66677afda9cc5c89c052e91348b4 (diff) | |
parent | c8e9937e21aa77de07316757667ed87dc2cc141e (diff) |
Merge pull request #7533 from GodotExplorer/pr-json-empty-string
Fix error while JSON::parse with empty string
Diffstat (limited to 'core/io/json.cpp')
-rw-r--r-- | core/io/json.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/io/json.cpp b/core/io/json.cpp index c0aa530a12..ac5b8f1e5f 100644 --- a/core/io/json.cpp +++ b/core/io/json.cpp @@ -100,7 +100,7 @@ String JSON::print(const Variant& p_var) { Error JSON::_get_token(const CharType *p_str, int &idx, int p_len, Token& r_token,int &line,String &r_err_str) { - while (true) { + while (p_len > 0) { switch(p_str[idx]) { case '\n': { |