Swap the buffer ids in move assignment

This makes the other object free the buffer on destruction.
Fixes #1