Some commands take a --frame or --thread, but the code had a common javascript error of if (numberVar) instead of if (numberVar !== undefined).
For threads this isn't often a problem as GDB doesn't use thread 0 typically. But for frames this is a problem as --frame 0 was being omitted, leaving GDB to return info about the last frame that was accessed, e.g like this:
Some commands take a --frame or --thread, but the code had a common javascript error of
if (numberVar)
instead ofif (numberVar !== undefined)
.For threads this isn't often a problem as GDB doesn't use thread 0 typically. But for frames this is a problem as
--frame 0
was being omitted, leaving GDB to return info about the last frame that was accessed, e.g like this:Because the second line doesn't include the frame, GDB uses frame 1 still. However that will lead to errors as it should be frame 0 that is queried.
Fixes #235