Resolve Coverity issue with Parser::Transition's ownership of Action *.

This commit is somewhat subtle; it informs Coverity that
Parser::Transition only holds an Action* temporarily, and should never
create/delete one.  I believe runtime checkers should also understand
this OK.

Signed-off-by: John Hood <cgull@glup.org>
This commit is contained in:
John Hood
2015-06-10 19:38:00 -04:00
parent 6f4a59e20f
commit 8acee95c02
3 changed files with 14 additions and 4 deletions
+1
View File
@@ -63,6 +63,7 @@ std::list<Parser::Action *> Parser::Parser::input( wchar_t ch )
}
append_or_delete( tx.action, ret );
tx.action = NULL;
if ( tx.next_state != NULL ) {
append_or_delete( tx.next_state->enter(), ret );