Fix compilation after API change for 0.7.1
Fix copying