remove memory leak. simplify setter for shape on edgeinfo