This would fail with EINVAL earlier, due to an attempt to create a zero-length Core::AnonymousBuffer. We fix this by transferring the buffer length separately, and only going down the AnonymousBuffer allocation path if the length is non-zero.