Remove unnecessary null checks before delete/free statements.