diff options
-rw-r--r-- | Server/Plugins/Debuggers/Debuggers.lua | 10 | ||||
m--------- | lib/lua | 0 |
2 files changed, 10 insertions, 0 deletions
diff --git a/Server/Plugins/Debuggers/Debuggers.lua b/Server/Plugins/Debuggers/Debuggers.lua index 2b9ed1bf0..7d7246484 100644 --- a/Server/Plugins/Debuggers/Debuggers.lua +++ b/Server/Plugins/Debuggers/Debuggers.lua @@ -2173,6 +2173,16 @@ function HandleConsoleTestJson(a_Split, a_EntireCmd) assert(type(msg) == "string") LOG("Json parsing an invalid string: Error message returned: " .. msg) + local isSuccess, t3 + isSuccess, t3, msg = pcall(cJson.Parse, cJson, nil) + if (isSuccess) then + LOG(string.format("Json parsing a 'nil' produced a %s and a %s, msg is %s.", + type(t3), type(msg), msg or "<nil>" + )) + else + LOG("Json parsing a 'nil' raised an error") + end + LOG("Json parsing test succeeded") LOG("Testing Json serializing...") diff --git a/lib/lua b/lib/lua -Subproject 9d4dbf9b7e83c0111a5798f1315920df989f94d +Subproject 5f54aca0d4272e5c260adb100e8249c560a853a |