Fixed all double free()s