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

Unified Diff: content/browser/gamepad/raw_input_data_fetcher_win.cc

Issue 1549113002: Switch to standard integer types in content/browser/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years 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
Index: content/browser/gamepad/raw_input_data_fetcher_win.cc
diff --git a/content/browser/gamepad/raw_input_data_fetcher_win.cc b/content/browser/gamepad/raw_input_data_fetcher_win.cc
index 670a022ad961bfe54a68043e87e2d1e32beb6503..0693eef9eb87b51ccefc95850f8d2d676ac6338e 100644
--- a/content/browser/gamepad/raw_input_data_fetcher_win.cc
+++ b/content/browser/gamepad/raw_input_data_fetcher_win.cc
@@ -4,6 +4,9 @@
#include "content/browser/gamepad/raw_input_data_fetcher_win.h"
+#include <stddef.h>
+
+#include "base/macros.h"
#include "base/trace_event/trace_event.h"
#include "content/common/gamepad_hardware_buffer.h"
#include "content/common/gamepad_messages.h"
@@ -187,7 +190,7 @@ RawGamepadInfo* RawInputDataFetcher::ParseGamepadInfo(HANDLE hDevice) {
}
DCHECK_EQ(0u, result);
- scoped_ptr<uint8[]> di_buffer(new uint8[size]);
+ scoped_ptr<uint8_t[]> di_buffer(new uint8_t[size]);
RID_DEVICE_INFO* device_info =
reinterpret_cast<RID_DEVICE_INFO*>(di_buffer.get());
result = GetRawInputDeviceInfo(hDevice, RIDI_DEVICEINFO,
@@ -266,7 +269,7 @@ RawGamepadInfo* RawInputDataFetcher::ParseGamepadInfo(HANDLE hDevice) {
}
DCHECK_EQ(0u, result);
- gamepad_info->ppd_buffer.reset(new uint8[size]);
+ gamepad_info->ppd_buffer.reset(new uint8_t[size]);
gamepad_info->preparsed_data =
reinterpret_cast<PHIDP_PREPARSED_DATA>(gamepad_info->ppd_buffer.get());
result = GetRawInputDeviceInfo(hDevice, RIDI_PREPARSEDDATA,
@@ -442,7 +445,7 @@ LRESULT RawInputDataFetcher::OnInput(HRAWINPUT input_handle) {
DCHECK_EQ(0u, result);
// Retrieve the input record.
- scoped_ptr<uint8[]> buffer(new uint8[size]);
+ scoped_ptr<uint8_t[]> buffer(new uint8_t[size]);
RAWINPUT* input = reinterpret_cast<RAWINPUT*>(buffer.get());
result = GetRawInputData(
input_handle, RID_INPUT, buffer.get(), &size, sizeof(RAWINPUTHEADER));
« no previous file with comments | « content/browser/gamepad/raw_input_data_fetcher_win.h ('k') | content/browser/gamepad/xbox_data_fetcher_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698