Possible memmory leak fix.