Fixed cpu + memory leak. Fixed some issues in DAO.stg and CucumberFeature.stg. refs #510 and #500