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

Unified Diff: chromeos/network/network_util.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
« no previous file with comments | « chromeos/network/network_util.h ('k') | chromeos/network/network_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/network/network_util.cc
diff --git a/chromeos/network/network_util.cc b/chromeos/network/network_util.cc
index af660e2aa27c18694710af996859148993fc0a63..a0f81816cf1200373af3e953a497e7b39fb36755 100644
--- a/chromeos/network/network_util.cc
+++ b/chromeos/network/network_util.cc
@@ -4,6 +4,9 @@
#include "chromeos/network/network_util.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_tokenizer.h"
#include "base/strings/string_util.h"
@@ -37,7 +40,7 @@ CellularScanResult::~CellularScanResult() {
namespace network_util {
-std::string PrefixLengthToNetmask(int32 prefix_length) {
+std::string PrefixLengthToNetmask(int32_t prefix_length) {
std::string netmask;
// Return the empty string for invalid inputs.
if (prefix_length < 0 || prefix_length > 32)
@@ -59,7 +62,7 @@ std::string PrefixLengthToNetmask(int32 prefix_length) {
return netmask;
}
-int32 NetmaskToPrefixLength(const std::string& netmask) {
+int32_t NetmaskToPrefixLength(const std::string& netmask) {
int count = 0;
int prefix_length = 0;
base::StringTokenizer t(netmask, ".");
« no previous file with comments | « chromeos/network/network_util.h ('k') | chromeos/network/network_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698