Use `aim_memdup`, which will not fail.