Fix use-after-free bug in unit test
Fix use-after-free bug in unit test

andre-senna/opencog,andre-senna/opencog,AmeBel/opencog,andre-senna/opencog,AmeBel/opencog,andre-senna/opencog,andre-senna/opencog,AmeBel/opencog,andre-senna/opencog,AmeBel/opencog,AmeBel/opencog,AmeBel/opencog,andre-senna/opencog,AmeBel/opencog