Update to work with latest master

This is segfaulting for me in places that should not segfault. Not sure
what's going on.