Fix bugs that kept this from running on sample heap dump