mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 09:08:20 +00:00
Improve script debugger backtrace and print commands.
Stack trace context descriptions are no longer limited to 1024 chars and better error messages are relayed when the arguments to print commands fail to parse (e.g. an "unknown identifier" was given).
This commit is contained in:
parent
da34266a52
commit
0c5afc59f7
3 changed files with 23 additions and 8 deletions
|
@ -553,7 +553,8 @@ int dbg_cmd_print(DebugCmd cmd, const vector<string>& args)
|
|||
for ( int i = 0; i < int(args.size()); ++i )
|
||||
{
|
||||
expr += args[i];
|
||||
expr += " ";
|
||||
if ( i < int(args.size()) - 1 )
|
||||
expr += " ";
|
||||
}
|
||||
|
||||
Val* val = dbg_eval_expr(expr.c_str());
|
||||
|
@ -566,8 +567,7 @@ int dbg_cmd_print(DebugCmd cmd, const vector<string>& args)
|
|||
}
|
||||
else
|
||||
{
|
||||
// ### Print something?
|
||||
// debug_msg("<expression has no value>\n");
|
||||
debug_msg("<expression has no value>\n");
|
||||
}
|
||||
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue