Add some missing frees. Thanks to John Darrington for reporting