mirror of
https://github.com/zeek/zeek.git
synced 2025-10-13 03:58:20 +00:00
memory-handling fixes for information associated with low-level ZAM instructions
This commit is contained in:
parent
e2646f9752
commit
e9b990254a
2 changed files with 3 additions and 4 deletions
|
@ -210,8 +210,7 @@ void ZAMCompiler::ResolveHookBreaks() {
|
|||
// Rewrite the breaks.
|
||||
for ( auto& b : breaks[0] ) {
|
||||
auto& i = insts1[b.stmt_num];
|
||||
delete i;
|
||||
i = new ZInstI(OP_HOOK_BREAK_X);
|
||||
*i = ZInstI(OP_HOOK_BREAK_X);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -197,8 +197,8 @@ void ZBody::SetInsts(vector<ZInstI*>& instsI) {
|
|||
if ( iI.stmt ) {
|
||||
auto l = iI.stmt->Original()->GetLocationInfo();
|
||||
if ( l != &no_location )
|
||||
insts_copy[i].loc = std::make_shared<Location>(util::copy_string(l->filename), l->first_line,
|
||||
l->last_line, l->first_column, l->last_column);
|
||||
insts_copy[i].loc = std::make_shared<Location>(l->filename, l->first_line, l->last_line,
|
||||
l->first_column, l->last_column);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue