Cython fix object lifetimes.