Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(197)

Unified Diff: device/hid/hid_connection_win.cc

Issue 604613002: Remove implicit HANDLE conversions from device. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « device/bluetooth/bluetooth_task_manager_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/hid/hid_connection_win.cc
diff --git a/device/hid/hid_connection_win.cc b/device/hid/hid_connection_win.cc
index 8e00ae03db499fa2c77067a5de89955a058b0fa4..8d0c63f1b4a2dc4e3f110662aca8b40657d9d2e8 100644
--- a/device/hid/hid_connection_win.cc
+++ b/device/hid/hid_connection_win.cc
@@ -208,7 +208,7 @@ void HidConnectionWin::OnReadComplete(scoped_refptr<net::IOBuffer> buffer,
DWORD bytes_transferred;
if (GetOverlappedResult(
- file_, transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
+ file_.Get(), transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
CompleteRead(buffer, bytes_transferred, callback);
} else {
VPLOG(1) << "HID read failed";
@@ -228,7 +228,7 @@ void HidConnectionWin::OnReadFeatureComplete(
DWORD bytes_transferred;
if (GetOverlappedResult(
- file_, transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
+ file_.Get(), transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
scoped_refptr<net::IOBuffer> new_buffer(
new net::IOBuffer(bytes_transferred - 1));
memcpy(new_buffer->data(), buffer->data() + 1, bytes_transferred - 1);
@@ -249,7 +249,7 @@ void HidConnectionWin::OnWriteComplete(const WriteCallback& callback,
DWORD bytes_transferred;
if (GetOverlappedResult(
- file_, transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
+ file_.Get(), transfer->GetOverlapped(), &bytes_transferred, FALSE)) {
callback.Run(true);
} else {
VPLOG(1) << "HID write failed";
« no previous file with comments | « device/bluetooth/bluetooth_task_manager_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698