summaryrefslogtreecommitdiffstats
path: root/device
diff options
context:
space:
mode:
authoryoungki@chromium.org <youngki@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-27 06:16:20 +0000
committeryoungki@chromium.org <youngki@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-27 06:16:20 +0000
commit2b1da855508d76bea54d771cc714e6bd69032a28 (patch)
treecbc64ad9d74702f7f476a3be3556c69261afbde0 /device
parent152972574a89ce3eedef9f1e34946cad136f381d (diff)
downloadchromium_src-2b1da855508d76bea54d771cc714e6bd69032a28.zip
chromium_src-2b1da855508d76bea54d771cc714e6bd69032a28.tar.gz
chromium_src-2b1da855508d76bea54d771cc714e6bd69032a28.tar.bz2
fixing the crash: pass the data pointer instead of the class pointer.
BUG= Review URL: https://chromiumcodereview.appspot.com/14307022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@196952 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'device')
-rw-r--r--device/bluetooth/bluetooth_socket_chromeos.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/device/bluetooth/bluetooth_socket_chromeos.cc b/device/bluetooth/bluetooth_socket_chromeos.cc
index c4781df..1558148 100644
--- a/device/bluetooth/bluetooth_socket_chromeos.cc
+++ b/device/bluetooth/bluetooth_socket_chromeos.cc
@@ -70,7 +70,7 @@ bool BluetoothSocketChromeOS::Receive(net::GrowableIOBuffer* buffer) {
do {
if (buffer->RemainingCapacity() == 0)
buffer->SetCapacity(buffer->capacity() * 2);
- bytes_read = read(fd_, buffer, buffer->RemainingCapacity());
+ bytes_read = read(fd_, buffer->data(), buffer->RemainingCapacity());
if (bytes_read > 0)
buffer->set_offset(buffer->offset() + bytes_read);
} while (bytes_read > 0);
@@ -85,7 +85,7 @@ bool BluetoothSocketChromeOS::Receive(net::GrowableIOBuffer* buffer) {
bool BluetoothSocketChromeOS::Send(net::DrainableIOBuffer* buffer) {
ssize_t bytes_written;
do {
- bytes_written = write(fd_, buffer, buffer->BytesRemaining());
+ bytes_written = write(fd_, buffer->data(), buffer->BytesRemaining());
if (bytes_written > 0)
buffer->DidConsume(bytes_written);
} while (buffer->BytesRemaining() > 0 && bytes_written > 0);