cleanup "neat_close" function and resolve unreachable code issue reported by coverity
cleanup "neat_close" function and resolve unreachable code issue reported by coverity

NEAT-project/neat,NEAT-project/neat,NEAT-project/neat,NEAT-project/neat,NEAT-project/neat