Make external reparent more robust.