Skip to content
Browse files

Fix crash when attempting to parse a stdout line with no key, e.g. " …

…:??"
  • Loading branch information...
1 parent 6c0760c commit 2574838da8849bc7534a7a872ec7fbfa2f3ebc84 @chriso chriso committed with Apr 4, 2012
Showing with 3 additions and 0 deletions.
  1. +3 −0 lib/getters.js
View
3 lib/getters.js
@@ -110,6 +110,9 @@ module.exports = function (gm) {
o = out.root = out.indent[level] = self.data;
} else if (indent < level) {
// outdent
+ if (!(indent in out.indent)) {
+ continue;
+ }
o = out.indent[indent];
} else if (indent > level) {
// dropping into a nested object

0 comments on commit 2574838

Please sign in to comment.
Something went wrong with that request. Please try again.