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

Unified Diff: chromeos/process_proxy/process_output_watcher.cc

Issue 1540803002: Switch to standard integer types in chromeos/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more includes 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: chromeos/process_proxy/process_output_watcher.cc
diff --git a/chromeos/process_proxy/process_output_watcher.cc b/chromeos/process_proxy/process_output_watcher.cc
index 92868c0e931a2622b2458c6d608f9913b8bb251a..c9f1916854d74bc060c03bc4816f3d4da165bf32 100644
--- a/chromeos/process_proxy/process_output_watcher.cc
+++ b/chromeos/process_proxy/process_output_watcher.cc
@@ -4,6 +4,9 @@
#include "chromeos/process_proxy/process_output_watcher.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <algorithm>
#include <cstdio>
#include <cstring>
@@ -23,10 +26,10 @@ namespace {
// byte. If the most significant bit is '0', the character is a valid ASCII
// and it's byte size is 1.
// The method returns 1 if the provided byte is invalid leading byte.
-size_t UTF8SizeFromLeadingByte(uint8 leading_byte) {
+size_t UTF8SizeFromLeadingByte(uint8_t leading_byte) {
size_t byte_count = 0;
- uint8 mask = 1 << 7;
- uint8 error_mask = 1 << (7 - CBU8_MAX_LENGTH);
+ uint8_t mask = 1 << 7;
+ uint8_t error_mask = 1 << (7 - CBU8_MAX_LENGTH);
while (leading_byte & mask) {
if (mask & error_mask)
return 1;
« no previous file with comments | « chromeos/process_proxy/process_output_watcher.h ('k') | chromeos/process_proxy/process_output_watcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698