Fix Copy to buffer