From 941c9b3c5cd6f0f1383f57fb6e89a705a8989032 Mon Sep 17 00:00:00 2001 From: jfcarroll Date: Wed, 6 Oct 2021 12:53:05 -0700 Subject: [PATCH] The final fixes for the socket code allowing us to advertise and accept the connection. PiperOrigin-RevId: 401317340 --- cpp/platform/impl/windows/bluetooth_classic_socket.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpp/platform/impl/windows/bluetooth_classic_socket.cc b/cpp/platform/impl/windows/bluetooth_classic_socket.cc index c54a3d9a..786ad8b7 100644 --- a/cpp/platform/impl/windows/bluetooth_classic_socket.cc +++ b/cpp/platform/impl/windows/bluetooth_classic_socket.cc @@ -119,8 +119,8 @@ BluetoothSocket::BluetoothOutputStream::BluetoothOutputStream( Exception BluetoothSocket::BluetoothOutputStream::Write(const ByteArray& data) { Buffer buffer = Buffer(data.size()); - std::memcpy(buffer.data(), data.data(), data.size()); + buffer.Length(data.size()); try { winrt_stream_.WriteAsync(buffer).get();