mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
fix heap-use-after-free
This commit is contained in:
@@ -411,11 +411,11 @@ dbgcmd_list(mrb_state *mrb, mrdb_state *mrdb)
|
||||
filename = st->filename;
|
||||
}
|
||||
mrb_debug_list(mrb, mrdb->dbg, filename, st->line_min, st->line_max);
|
||||
listcmd_parser_state_free(mrb, st);
|
||||
|
||||
if (filename != NULL && filename != st->filename) {
|
||||
mrb_free(mrb, filename);
|
||||
}
|
||||
listcmd_parser_state_free(mrb, st);
|
||||
}
|
||||
|
||||
return DBGST_PROMPT;
|
||||
|
||||
Reference in New Issue
Block a user