model: fix leaking "pending actions"
authorBrian Norris <banorris@uci.edu>
Fri, 15 Feb 2013 19:02:05 +0000 (11:02 -0800)
committerBrian Norris <banorris@uci.edu>
Fri, 15 Feb 2013 22:55:02 +0000 (14:55 -0800)
commitfcae856e66379752f8d227784d28c424206ab0c1
tree9fffea0712f913ed57c299274e507287574059e5
parent61eabdb86ab3a0a9a3051bd0bbf4dfed2172fdce
model: fix leaking "pending actions"

ModelActions that are "pending" for each thread are not automatically
freed when we rollback; we keep most of the active ModelActions on the
NodeStack, then we free them from there when we explore a new branch of
the state space.

This fix causes all the pending actions to be freed on any rollback.
This is safe for now, since we always roll back to the beginning of the
execution. If we roll back to an intermediate point, though, we need to
retain those pending actions which were also pending before the rollback
point. Hence the FIXME notice included in reset_to_initial_state().
model.cc