Bug 787933 - Stop using stdin types in IPC code; r=bsmedberg+cjones sr=cjones
authorMs2ger <ms2ger@gmail.com>
Mon, 17 Sep 2012 10:37:20 +0200
changeset 113478 5139419511404382a05b98e01690d00f7cf4e530
parent 113477 1ca103a4a48190e7a724b742b70072011762fe5c
child 113479 c54c070b1d70e25d281e571360bdf7ea7a617d74
push idunknown
push userunknown
push dateunknown
reviewersbsmedberg, cjones
bugs787933
milestone18.0a1
Bug 787933 - Stop using stdin types in IPC code; r=bsmedberg+cjones sr=cjones
dom/indexedDB/IDBIndex.cpp
dom/ipc/ContentParent.cpp
dom/ipc/ContentParent.h
dom/ipc/TabMessageUtils.h
dom/plugins/ipc/PluginInstanceChild.cpp
dom/plugins/ipc/PluginMessageUtils.h
dom/plugins/ipc/PluginModuleParent.cpp
dom/plugins/ipc/PluginProcessParent.cpp
gfx/layers/ipc/ShadowLayerUtils.h
hal/sandbox/PHal.ipdl
ipc/chromium/src/base/atomicops.h
ipc/chromium/src/base/atomicops_internals_x86_gcc.cc
ipc/chromium/src/base/base_drop_target.cc
ipc/chromium/src/base/base_drop_target.h
ipc/chromium/src/base/basictypes.h
ipc/chromium/src/base/condition_variable_posix.cc
ipc/chromium/src/base/crypto/signature_verifier.h
ipc/chromium/src/base/crypto/signature_verifier_mac.cc
ipc/chromium/src/base/crypto/signature_verifier_nss.cc
ipc/chromium/src/base/crypto/signature_verifier_unittest.cc
ipc/chromium/src/base/crypto/signature_verifier_win.cc
ipc/chromium/src/base/data_pack.cc
ipc/chromium/src/base/file_util.cc
ipc/chromium/src/base/file_util.h
ipc/chromium/src/base/file_util_posix.cc
ipc/chromium/src/base/file_util_unittest.cc
ipc/chromium/src/base/file_util_win.cc
ipc/chromium/src/base/file_version_info.cc
ipc/chromium/src/base/histogram.cc
ipc/chromium/src/base/histogram.h
ipc/chromium/src/base/histogram_unittest.cc
ipc/chromium/src/base/id_map.h
ipc/chromium/src/base/idle_timer.cc
ipc/chromium/src/base/idle_timer.h
ipc/chromium/src/base/idletimer_unittest.cc
ipc/chromium/src/base/lazy_instance.h
ipc/chromium/src/base/lock_impl.h
ipc/chromium/src/base/md5.cc
ipc/chromium/src/base/message_pump_qt.cc
ipc/chromium/src/base/pickle.cc
ipc/chromium/src/base/pickle.h
ipc/chromium/src/base/pickle_unittest.cc
ipc/chromium/src/base/process_util.h
ipc/chromium/src/base/process_util_posix.cc
ipc/chromium/src/base/process_util_unittest.cc
ipc/chromium/src/base/process_util_win.cc
ipc/chromium/src/base/rand_util.cc
ipc/chromium/src/base/rand_util.h
ipc/chromium/src/base/rand_util_posix.cc
ipc/chromium/src/base/rand_util_win.cc
ipc/chromium/src/base/scoped_bstr_win.cc
ipc/chromium/src/base/scoped_bstr_win.h
ipc/chromium/src/base/scoped_bstr_win_unittest.cc
ipc/chromium/src/base/scoped_variant_win.cc
ipc/chromium/src/base/scoped_variant_win.h
ipc/chromium/src/base/scoped_variant_win_unittest.cc
ipc/chromium/src/base/shared_memory_unittest.cc
ipc/chromium/src/base/stats_counters.h
ipc/chromium/src/base/stats_table_unittest.cc
ipc/chromium/src/base/string16.h
ipc/chromium/src/base/string_util.cc
ipc/chromium/src/base/string_util.h
ipc/chromium/src/base/string_util_icu.cc
ipc/chromium/src/base/string_util_unittest.cc
ipc/chromium/src/base/sys_info.h
ipc/chromium/src/base/sys_info_mac.cc
ipc/chromium/src/base/sys_info_posix.cc
ipc/chromium/src/base/sys_info_unittest.cc
ipc/chromium/src/base/sys_info_win.cc
ipc/chromium/src/base/sys_string_conversions.h
ipc/chromium/src/base/sys_string_conversions_win.cc
ipc/chromium/src/base/test_file_util_mac.cc
ipc/chromium/src/base/time.cc
ipc/chromium/src/base/time.h
ipc/chromium/src/base/time_mac.cc
ipc/chromium/src/base/time_posix.cc
ipc/chromium/src/base/time_win.cc
ipc/chromium/src/base/time_win_unittest.cc
ipc/chromium/src/base/trace_event.cc
ipc/chromium/src/base/tracked_objects.cc
ipc/chromium/src/base/tracked_objects.h
ipc/chromium/src/base/version.cc
ipc/chromium/src/base/version.h
ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.cc
ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.h
ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.cc
ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.h
ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.cc
ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.h
ipc/chromium/src/chrome/common/child_process_host.cc
ipc/chromium/src/chrome/common/child_process_host.h
ipc/chromium/src/chrome/common/child_thread.cc
ipc/chromium/src/chrome/common/child_thread.h
ipc/chromium/src/chrome/common/chrome_plugin_api.h
ipc/chromium/src/chrome/common/chrome_plugin_lib.cc
ipc/chromium/src/chrome/common/chrome_plugin_util.cc
ipc/chromium/src/chrome/common/chrome_plugin_util.h
ipc/chromium/src/chrome/common/filter_policy.h
ipc/chromium/src/chrome/common/gears_api.h
ipc/chromium/src/chrome/common/gfx/color_utils.cc
ipc/chromium/src/chrome/common/gfx/emf.cc
ipc/chromium/src/chrome/common/gfx/emf.h
ipc/chromium/src/chrome/common/ipc_channel.h
ipc/chromium/src/chrome/common/ipc_channel_proxy.cc
ipc/chromium/src/chrome/common/ipc_channel_proxy.h
ipc/chromium/src/chrome/common/ipc_fuzzing_tests.cc
ipc/chromium/src/chrome/common/ipc_logging.cc
ipc/chromium/src/chrome/common/ipc_logging.h
ipc/chromium/src/chrome/common/ipc_message.cc
ipc/chromium/src/chrome/common/ipc_message.h
ipc/chromium/src/chrome/common/ipc_message_macros.h
ipc/chromium/src/chrome/common/ipc_message_utils.cc
ipc/chromium/src/chrome/common/ipc_message_utils.h
ipc/chromium/src/chrome/common/ipc_sync_message.cc
ipc/chromium/src/chrome/common/ipc_sync_message.h
ipc/chromium/src/chrome/common/ipc_test_sink.cc
ipc/chromium/src/chrome/common/ipc_test_sink.h
ipc/chromium/src/chrome/common/message_router.cc
ipc/chromium/src/chrome/common/message_router.h
ipc/chromium/src/chrome/common/page_transition_types.h
ipc/chromium/src/chrome/common/plugin_messages.h
ipc/chromium/src/chrome/common/plugin_messages_internal.h
ipc/chromium/src/chrome/common/pref_service.cc
ipc/chromium/src/chrome/common/pref_service.h
ipc/chromium/src/chrome/common/render_messages.h
ipc/chromium/src/chrome/common/render_messages_internal.h
ipc/chromium/src/chrome/common/resource_dispatcher.cc
ipc/chromium/src/chrome/common/resource_dispatcher.h
ipc/chromium/src/chrome/common/resource_dispatcher_unittest.cc
ipc/chromium/src/chrome/common/security_filter_peer.cc
ipc/chromium/src/chrome/common/security_filter_peer.h
ipc/chromium/src/chrome/common/transport_dib.h
ipc/chromium/src/chrome/common/transport_dib_linux.cc
ipc/chromium/src/chrome/common/transport_dib_mac.cc
ipc/chromium/src/chrome/common/transport_dib_win.cc
ipc/chromium/src/chrome/common/visitedlink_common.cc
ipc/chromium/src/chrome/common/visitedlink_common.h
ipc/chromium/src/testing/gtest/include/gtest/internal/gtest-port.h
ipc/glue/AsyncChannel.cpp
ipc/glue/AsyncChannel.h
ipc/glue/GeckoChildProcessHost.cpp
ipc/glue/GeckoChildProcessHost.h
ipc/glue/IPCMessageUtils.h
ipc/glue/ProtocolUtils.cpp
ipc/glue/ProtocolUtils.h
ipc/glue/RPCChannel.cpp
ipc/glue/RPCChannel.h
ipc/glue/Shmem.cpp
ipc/glue/Shmem.h
ipc/glue/SyncChannel.cpp
ipc/glue/SyncChannel.h
ipc/glue/WindowsMessageLoop.cpp
ipc/ipdl/ipdl/builtin.py
ipc/ipdl/ipdl/cxx/ast.py
ipc/ipdl/ipdl/lower.py
ipc/ipdl/test/cxx/TestDataStructures.cpp
ipc/ipdl/test/cxx/TestDataStructures.h
js/ipc/ObjectWrapperChild.cpp
--- a/dom/indexedDB/IDBIndex.cpp
+++ b/dom/indexedDB/IDBIndex.cpp
@@ -1387,17 +1387,17 @@ GetAllKeysHelper::GetSuccessResult(JSCon
   }
 
   if (!keys.IsEmpty()) {
     if (!JS_SetArrayLength(aCx, array, uint32_t(keys.Length()))) {
       NS_WARNING("Failed to set array length!");
       return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR;
     }
 
-    for (uint32 index = 0, count = keys.Length(); index < count; index++) {
+    for (uint32_t index = 0, count = keys.Length(); index < count; index++) {
       const Key& key = keys[index];
       NS_ASSERTION(!key.IsUnset(), "Bad key!");
 
       jsval value;
       nsresult rv = key.ToJSVal(aCx, &value);
       if (NS_FAILED(rv)) {
         NS_WARNING("Failed to get jsval for key!");
         return rv;
--- a/dom/ipc/ContentParent.cpp
+++ b/dom/ipc/ContentParent.cpp
@@ -483,17 +483,17 @@ ContentParent::MarkAsDead()
             gPrivateContent = NULL;
         }
     }
 
     mIsAlive = false;
 }
 
 void
-ContentParent::OnChannelConnected(int32 pid)
+ContentParent::OnChannelConnected(int32_t pid)
 {
     ProcessHandle handle;
     if (!base::OpenPrivilegedProcessHandle(pid, &handle)) {
         NS_WARNING("Can't open handle to child process.");
     }
     else {
         SetOtherProcess(handle);
 
--- a/dom/ipc/ContentParent.h
+++ b/dom/ipc/ContentParent.h
@@ -115,17 +115,17 @@ public:
     /**
      * Kill our subprocess and make sure it dies.  Should only be used
      * in emergency situations since it bypasses the normal shutdown
      * process.
      */
     void KillHard();
 
 protected:
-    void OnChannelConnected(int32 pid);
+    void OnChannelConnected(int32_t pid);
     virtual void ActorDestroy(ActorDestroyReason why);
 
 private:
     typedef base::ChildPrivileges ChildOSPrivileges;
 
     static nsDataHashtable<nsStringHashKey, ContentParent*> *gAppContentParents;
     static nsTArray<ContentParent*>* gNonAppContentParents;
     static nsTArray<ContentParent*>* gPrivateContent;
--- a/dom/ipc/TabMessageUtils.h
+++ b/dom/ipc/TabMessageUtils.h
@@ -23,17 +23,17 @@ struct RemoteDOMEvent
 
 bool ReadRemoteEvent(const IPC::Message* aMsg, void** aIter,
                      mozilla::dom::RemoteDOMEvent* aResult);
 
 #ifdef MOZ_CRASHREPORTER
 typedef CrashReporter::ThreadId NativeThreadId;
 #else
 // unused in this case
-typedef int32 NativeThreadId;
+typedef int32_t NativeThreadId;
 #endif
 
 }
 }
 
 namespace IPC {
 
 template<>
--- a/dom/plugins/ipc/PluginInstanceChild.cpp
+++ b/dom/plugins/ipc/PluginInstanceChild.cpp
@@ -544,17 +544,17 @@ PluginInstanceChild::NPN_SetValue(NPPVar
         if (!CallNPN_SetValue_NPPVpluginUsesDOMForCursor((NPBool)(intptr_t)aValue, &rv)) {
             return NPERR_GENERIC_ERROR;
         }
         return rv;
     }
 
     case NPPVpluginDrawingModel: {
         NPError rv;
-        int drawingModel = (int16) (intptr_t) aValue;
+        int drawingModel = (int16_t) (intptr_t) aValue;
 
         if (!PluginModuleChild::current()->AsyncDrawingAllowed() &&
             IsDrawingModelAsync(drawingModel)) {
             return NPERR_GENERIC_ERROR;
         }              
 
         CrossProcessMutexHandle handle;
         OptionalShmem optionalShmem;
@@ -581,17 +581,17 @@ PluginInstanceChild::NPN_SetValue(NPPVar
             mDrawingModel));
 
         return rv;
     }
 
 #ifdef XP_MACOSX
     case NPPVpluginEventModel: {
         NPError rv;
-        int eventModel = (int16) (intptr_t) aValue;
+        int eventModel = (int16_t) (intptr_t) aValue;
 
         if (!CallNPN_SetValue_NPPVpluginEventModel(eventModel, &rv))
             return NPERR_GENERIC_ERROR;
 #if defined(__i386__)
         mEventModel = static_cast<NPEventModel>(eventModel);
 #endif
 
         PLUGIN_LOG_DEBUG(("  Plugin requested event model id # %i\n",
--- a/dom/plugins/ipc/PluginMessageUtils.h
+++ b/dom/plugins/ipc/PluginMessageUtils.h
@@ -311,58 +311,58 @@ struct ParamTraits<NPRect>
 
 template <>
 struct ParamTraits<NPWindowType>
 {
   typedef NPWindowType paramType;
 
   static void Write(Message* aMsg, const paramType& aParam)
   {
-    aMsg->WriteInt16(int16(aParam));
+    aMsg->WriteInt16(int16_t(aParam));
   }
 
   static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
   {
-    int16 result;
+    int16_t result;
     if (aMsg->ReadInt16(aIter, &result)) {
       *aResult = paramType(result);
       return true;
     }
     return false;
   }
 
   static void Log(const paramType& aParam, std::wstring* aLog)
   {
-    aLog->append(StringPrintf(L"%d", int16(aParam)));
+    aLog->append(StringPrintf(L"%d", int16_t(aParam)));
   }
 };
 
 template <>
 struct ParamTraits<NPImageFormat>
 {
   typedef NPImageFormat paramType;
 
   static void Write(Message* aMsg, const paramType& aParam)
   {
-    aMsg->WriteInt16(int16(aParam));
+    aMsg->WriteInt16(int16_t(aParam));
   }
 
   static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
   {
-    int16 result;
+    int16_t result;
     if (aMsg->ReadInt16(aIter, &result)) {
       *aResult = paramType(result);
       return true;
     }
     return false;
   }
 
   static void Log(const paramType& aParam, std::wstring* aLog)
   {
-    aLog->append(StringPrintf(L"%d", int16(aParam)));
+    aLog->append(StringPrintf(L"%d", int16_t(aParam)));
   }
 };
 
 template <>
 struct ParamTraits<mozilla::plugins::NPRemoteWindow>
 {
   typedef mozilla::plugins::NPRemoteWindow paramType;
 
@@ -381,17 +381,17 @@ struct ParamTraits<mozilla::plugins::NPR
 #endif
 #if defined(XP_WIN)
     WriteParam(aMsg, aParam.surfaceHandle);
 #endif
   }
 
   static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
   {
-    uint64 window;
+    uint64_t window;
     int32_t x, y;
     uint32_t width, height;
     NPRect clipRect;
     NPWindowType type;
     if (!(aMsg->ReadUInt64(aIter, &window) &&
           ReadParam(aMsg, aIter, &x) &&
           ReadParam(aMsg, aIter, &y) &&
           ReadParam(aMsg, aIter, &width) &&
@@ -707,17 +707,17 @@ struct ParamTraits<NPVariant>
         bool value;
         if (ReadParam(aMsg, aIter, &value)) {
           BOOLEAN_TO_NPVARIANT(value, *aResult);
           return true;
         }
       } break;
 
       case 3: {
-        int32 value;
+        int32_t value;
         if (ReadParam(aMsg, aIter, &value)) {
           INT32_TO_NPVARIANT(value, *aResult);
           return true;
         }
       } break;
 
       case 4: {
         double value;
@@ -851,22 +851,22 @@ struct ParamTraits<NPNURLVariable>
   
 template<>
 struct ParamTraits<NPCoordinateSpace>
 {
   typedef NPCoordinateSpace paramType;
 
   static void Write(Message* aMsg, const paramType& aParam)
   {
-    WriteParam(aMsg, int32(aParam));
+    WriteParam(aMsg, int32_t(aParam));
   }
 
   static bool Read(const Message* aMsg, void** aIter, paramType* aResult)
   {
-    int32 intval;
+    int32_t intval;
     if (ReadParam(aMsg, aIter, &intval)) {
       switch (intval) {
       case NPCoordinateSpacePlugin:
       case NPCoordinateSpaceWindow:
       case NPCoordinateSpaceFlippedWindow:
       case NPCoordinateSpaceScreen:
       case NPCoordinateSpaceFlippedScreen:
         *aResult = paramType(intval);
--- a/dom/plugins/ipc/PluginModuleParent.cpp
+++ b/dom/plugins/ipc/PluginModuleParent.cpp
@@ -198,17 +198,17 @@ PluginModuleParent::WriteExtraDataForMin
 
 int
 PluginModuleParent::TimeoutChanged(const char* aPref, void* aModule)
 {
     NS_ASSERTION(NS_IsMainThread(), "Wrong thead!");
     if (!strcmp(aPref, kChildTimeoutPref)) {
       // The timeout value used by the parent for children
       int32_t timeoutSecs = Preferences::GetInt(kChildTimeoutPref, 0);
-      int32 timeoutMs = (timeoutSecs > 0) ? (1000 * timeoutSecs) :
+      int32_t timeoutMs = (timeoutSecs > 0) ? (1000 * timeoutSecs) :
                         SyncChannel::kNoTimeout;
       static_cast<PluginModuleParent*>(aModule)->SetReplyTimeoutMs(timeoutMs);
     } else if (!strcmp(aPref, kParentTimeoutPref)) {
       // The timeout value used by the child for its parent
       int32_t timeoutSecs = Preferences::GetInt(kParentTimeoutPref, 0);
       unused << static_cast<PluginModuleParent*>(aModule)->SendSetParentHangTimeout(timeoutSecs);
     }
     return 0;
--- a/dom/plugins/ipc/PluginProcessParent.cpp
+++ b/dom/plugins/ipc/PluginProcessParent.cpp
@@ -36,19 +36,19 @@ PluginProcessParent::PluginProcessParent
 PluginProcessParent::~PluginProcessParent()
 {
 }
 
 bool
 PluginProcessParent::Launch(int32_t timeoutMs)
 {
     ProcessArchitecture currentArchitecture = base::GetCurrentProcessArchitecture();
-    uint32 containerArchitectures = GetSupportedArchitecturesForProcessType(GeckoProcessType_Plugin);
+    uint32_t containerArchitectures = GetSupportedArchitecturesForProcessType(GeckoProcessType_Plugin);
 
-    uint32 pluginLibArchitectures = currentArchitecture;
+    uint32_t pluginLibArchitectures = currentArchitecture;
 #ifdef XP_MACOSX
     nsresult rv = GetArchitecturesForBinary(mPluginFilePath.c_str(), &pluginLibArchitectures);
     if (NS_FAILED(rv)) {
         // If the call failed just assume that we want the current architecture.
         pluginLibArchitectures = currentArchitecture;
     }
 #endif
 
--- a/gfx/layers/ipc/ShadowLayerUtils.h
+++ b/gfx/layers/ipc/ShadowLayerUtils.h
@@ -49,24 +49,24 @@ struct ParamTraits<mozilla::layers::Surf
 
 template<>
 struct ParamTraits<mozilla::gl::TextureImage::TextureShareType>
 {
   typedef mozilla::gl::TextureImage::TextureShareType paramType;
 
   static void Write(Message* msg, const paramType& param)
   {
-    MOZ_STATIC_ASSERT(sizeof(paramType) <= sizeof(int32),
-                      "TextureShareType assumes to be int32");
-    WriteParam(msg, int32(param));
+    MOZ_STATIC_ASSERT(sizeof(paramType) <= sizeof(int32_t),
+                      "TextureShareType assumes to be int32_t");
+    WriteParam(msg, int32_t(param));
   }
 
   static bool Read(const Message* msg, void** iter, paramType* result)
   {
-    int32 type;
+    int32_t type;
     if (!ReadParam(msg, iter, &type))
       return false;
 
     *result = paramType(type);
     return true;
   }
 };
 
--- a/hal/sandbox/PHal.ipdl
+++ b/hal/sandbox/PHal.ipdl
@@ -107,17 +107,17 @@ parent:
     SetScreenEnabled(bool enabled);
 
     sync GetCpuSleepAllowed() returns (bool allowed);
     SetCpuSleepAllowed(bool allowed);
 
     sync GetScreenBrightness() returns (double brightness);
     SetScreenBrightness(double brightness);
 
-    AdjustSystemClock(int32 aDeltaMilliseconds);
+    AdjustSystemClock(int32_t aDeltaMilliseconds);
     SetTimezone(nsCString aTimezoneSpec);
     sync GetTimezone()
       returns (nsCString aTimezoneSpec);
 
     sync SetLight(LightType light, LightConfiguration aConfig)
       returns (bool status);
     sync GetLight(LightType light)
       returns (LightConfiguration aConfig, bool status);
--- a/ipc/chromium/src/base/atomicops.h
+++ b/ipc/chromium/src/base/atomicops.h
@@ -33,28 +33,32 @@
 
 namespace base {
 namespace subtle {
 
 // Bug 1308991.  We need this for /Wp64, to mark it safe for AtomicWord casting.
 #ifndef OS_WIN
 #define __w64
 #endif
-typedef __w64 int32 Atomic32;
+typedef __w64 int32_t Atomic32;
 #ifdef ARCH_CPU_64_BITS
-typedef int64 Atomic64;
+typedef int64_t Atomic64;
 #endif
 
 // Use AtomicWord for a machine-sized pointer.  It will use the Atomic32 or
 // Atomic64 routines below, depending on your architecture.
-#if defined(OS_OPENBSD) && !defined(ARCH_CPU_64_BITS)
+#ifdef OS_OPENBSD
+#ifdef ARCH_CPU_64_BITS
+typedef Atomic64 AtomicWord;
+#else
 typedef Atomic32 AtomicWord;
+#endif // ARCH_CPU_64_BITS
 #else
 typedef intptr_t AtomicWord;
-#endif
+#endif // OS_OPENBSD
 
 // Atomically execute:
 //      result = *ptr;
 //      if (*ptr == old_value)
 //        *ptr = new_value;
 //      return result;
 //
 // I.e., replace "*ptr" with "new_value" if "*ptr" used to be "old_value".
--- a/ipc/chromium/src/base/atomicops_internals_x86_gcc.cc
+++ b/ipc/chromium/src/base/atomicops_internals_x86_gcc.cc
@@ -40,20 +40,20 @@
 // default values should hopefully be pretty safe.
 struct AtomicOps_x86CPUFeatureStruct AtomicOps_Internalx86CPUFeatures = {
   false,          // bug can't exist before process spawns multiple threads
   false,          // no SSE2
 };
 
 // Initialize the AtomicOps_Internalx86CPUFeatures struct.
 static void AtomicOps_Internalx86CPUFeaturesInit() {
-  uint32 eax;
-  uint32 ebx;
-  uint32 ecx;
-  uint32 edx;
+  uint32_t eax;
+  uint32_t ebx;
+  uint32_t ecx;
+  uint32_t edx;
 
   // Get vendor string (issue CPUID with eax = 0)
   cpuid(eax, ebx, ecx, edx, 0);
   char vendor[13];
   memcpy(vendor, &ebx, 4);
   memcpy(vendor + 4, &edx, 4);
   memcpy(vendor + 8, &ecx, 4);
   vendor[12] = 0;
--- a/ipc/chromium/src/base/base_drop_target.cc
+++ b/ipc/chromium/src/base/base_drop_target.cc
@@ -6,17 +6,17 @@
 
 #include <shlobj.h>
 
 #include "base/logging.h"
 
 ///////////////////////////////////////////////////////////////////////////////
 
 IDropTargetHelper* BaseDropTarget::cached_drop_target_helper_ = NULL;
-int32 BaseDropTarget::drag_identity_ = 0;
+int32_t BaseDropTarget::drag_identity_ = 0;
 
 BaseDropTarget::BaseDropTarget(HWND hwnd)
     : hwnd_(hwnd),
       suspend_(false),
       ref_count_(0) {
   DCHECK(hwnd);
   HRESULT result = RegisterDragDrop(hwnd, this);
   DCHECK(SUCCEEDED(result));
--- a/ipc/chromium/src/base/base_drop_target.h
+++ b/ipc/chromium/src/base/base_drop_target.h
@@ -81,17 +81,17 @@ class BaseDropTarget : public IDropTarge
   // Invoked when the drop ends on the window. This should return the operation
   // that was taken.
   virtual DWORD OnDrop(IDataObject* data_object,
                        DWORD key_state,
                        POINT cursor_position,
                        DWORD effect);
 
   // Return the drag identity.
-  static int32 GetDragIdentity() { return drag_identity_; }
+  static int32_t GetDragIdentity() { return drag_identity_; }
 
  private:
   // Returns the cached drop helper, creating one if necessary. The returned
   // object is not addrefed. May return NULL if the object couldn't be created.
   static IDropTargetHelper* DropHelper();
 
   // The data object currently being dragged over this drop target.
   scoped_refptr<IDataObject> current_data_object_;
@@ -105,19 +105,19 @@ class BaseDropTarget : public IDropTarge
   // since often, DnD will never be used. Instead, we force this penalty to the
   // first time it is actually used.
   static IDropTargetHelper* cached_drop_target_helper_;
 
   // The drag identity (id). An up-counter that increases when the cursor first
   // moves over the HWND in a DnD session (OnDragEnter). 0 is reserved to mean
   // the "no/unknown" identity, and is used for initialization. The identity is
   // sent to the renderer in drag enter notifications. Note: the identity value
-  // is passed over the renderer NPAPI interface to gears, so use int32 instead
+  // is passed over the renderer NPAPI interface to gears, so use int32_t instead
   // of int here.
-  static int32 drag_identity_;
+  static int32_t drag_identity_;
 
   // The HWND of the source. This HWND is used to determine coordinates for
   // mouse events that are sent to the renderer notifying various drag states.
   HWND hwnd_;
 
   // Whether or not we are currently processing drag notifications for drags
   // initiated in this window.
   bool suspend_;
--- a/ipc/chromium/src/base/basictypes.h
+++ b/ipc/chromium/src/base/basictypes.h
@@ -19,57 +19,42 @@
 
 #include "prtypes.h"
 
 #ifdef NO_NSPR_10_SUPPORT_SAVE
 #undef NO_NSPR_10_SUPPORT_SAVE
 #undef NO_NSPR_10_SUPPORT
 #endif
 
-#ifdef _WIN32
-#undef _WIN32
-#define _WIN32_SAVE
-#endif
-
-#include "obsolete/protypes.h"
-
-#ifdef _WIN32_SAVE
-#undef _WIN32_SAVE
-#define _WIN32
-#endif
-
 #include <limits.h>         // So we can set the bounds of our types
 #include <stddef.h>         // For size_t
 #include <string.h>         // for memcpy
 
 #include "base/port.h"    // Types that only need exist on certain systems
 
-#ifndef COMPILER_MSVC
-// stdint.h is part of C99 but MSVC doesn't have it.
-#include <stdint.h>         // For intptr_t.
-#endif
+#include "mozilla/StandardInteger.h"
 
 // A type to represent a Unicode code-point value. As of Unicode 4.0,
 // such values require up to 21 bits.
 // (For type-checking on pointers, make this explicitly signed,
-// and it should always be the signed version of whatever int32 is.)
+// and it should always be the signed version of whatever int32_t is.)
 typedef signed int         char32;
 
-const uint8  kuint8max  = (( uint8) 0xFF);
-const uint16 kuint16max = ((uint16) 0xFFFF);
-const uint32 kuint32max = ((uint32) 0xFFFFFFFF);
-const uint64 kuint64max = ((uint64) GG_LONGLONG(0xFFFFFFFFFFFFFFFF));
-const  int8  kint8min   = ((  int8) 0x80);
-const  int8  kint8max   = ((  int8) 0x7F);
-const  int16 kint16min  = (( int16) 0x8000);
-const  int16 kint16max  = (( int16) 0x7FFF);
-const  int32 kint32min  = (( int32) 0x80000000);
-const  int32 kint32max  = (( int32) 0x7FFFFFFF);
-const  int64 kint64min  = (( int64) GG_LONGLONG(0x8000000000000000));
-const  int64 kint64max  = (( int64) GG_LONGLONG(0x7FFFFFFFFFFFFFFF));
+const uint8_t  kuint8max  = (( uint8_t) 0xFF);
+const uint16_t kuint16max = ((uint16_t) 0xFFFF);
+const uint32_t kuint32max = ((uint32_t) 0xFFFFFFFF);
+const uint64_t kuint64max = ((uint64_t) GG_LONGLONG(0xFFFFFFFFFFFFFFFF));
+const  int8_t  kint8min   = ((  int8_t) 0x80);
+const  int8_t  kint8max   = ((  int8_t) 0x7F);
+const  int16_t kint16min  = (( int16_t) 0x8000);
+const  int16_t kint16max  = (( int16_t) 0x7FFF);
+const  int32_t kint32min  = (( int32_t) 0x80000000);
+const  int32_t kint32max  = (( int32_t) 0x7FFFFFFF);
+const  int64_t kint64min  = (( int64_t) GG_LONGLONG(0x8000000000000000));
+const  int64_t kint64max  = (( int64_t) GG_LONGLONG(0x7FFFFFFFFFFFFFFF));
 
 // Platform- and hardware-dependent printf specifiers
 #  if defined(OS_POSIX)
 #    define __STDC_FORMAT_MACROS 1
 #    include <inttypes.h>           // for 64-bit integer format macros
 #    define PRId64L "I64d"
 #    define PRIu64L "I64u"
 #    define PRIx64L "I64x"
@@ -254,33 +239,33 @@ struct CompileAssert {
 //     ((expr) ? 1 : -1).
 //
 //   This is to avoid running into a bug in MS VC 7.1, which
 //   causes ((0.0) ? 1 : -1) to incorrectly evaluate to 1.
 
 
 // MetatagId refers to metatag-id that we assign to
 // each metatag <name, value> pair..
-typedef uint32 MetatagId;
+typedef uint32_t MetatagId;
 
 // Argument type used in interfaces that can optionally take ownership
 // of a passed in argument.  If TAKE_OWNERSHIP is passed, the called
 // object takes ownership of the argument.  Otherwise it does not.
 enum Ownership {
   DO_NOT_TAKE_OWNERSHIP,
   TAKE_OWNERSHIP
 };
 
 // bit_cast<Dest,Source> is a template function that implements the
 // equivalent of "*reinterpret_cast<Dest*>(&source)".  We need this in
 // very low-level functions like the protobuf library and fast math
 // support.
 //
 //   float f = 3.14159265358979;
-//   int i = bit_cast<int32>(f);
+//   int i = bit_cast<int32_t>(f);
 //   // i = 0x40490fdb
 //
 // The classical address-casting method is:
 //
 //   // WRONG
 //   float f = 3.14159265358979;            // WRONG
 //   int i = * reinterpret_cast<int*>(&f);  // WRONG
 //
--- a/ipc/chromium/src/base/condition_variable_posix.cc
+++ b/ipc/chromium/src/base/condition_variable_posix.cc
@@ -27,17 +27,17 @@ ConditionVariable::~ConditionVariable() 
 }
 
 void ConditionVariable::Wait() {
   int rv = pthread_cond_wait(&condition_, user_mutex_);
   DCHECK(rv == 0);
 }
 
 void ConditionVariable::TimedWait(const TimeDelta& max_time) {
-  int64 usecs = max_time.InMicroseconds();
+  int64_t usecs = max_time.InMicroseconds();
 
   // The timeout argument to pthread_cond_timedwait is in absolute time.
   struct timeval now;
   gettimeofday(&now, NULL);
 
   struct timespec abstime;
   abstime.tv_sec = now.tv_sec + (usecs / Time::kMicrosecondsPerSecond);
   abstime.tv_nsec = (now.tv_usec + (usecs % Time::kMicrosecondsPerSecond)) *
--- a/ipc/chromium/src/base/crypto/signature_verifier.h
+++ b/ipc/chromium/src/base/crypto/signature_verifier.h
@@ -46,50 +46,50 @@ class SignatureVerifier {
   // big-endian byte order.
   //
   // The public key is specified as a DER encoded ASN.1 SubjectPublicKeyInfo
   // structure, which contains not only the public key but also its type
   // (algorithm):
   //   SubjectPublicKeyInfo  ::=  SEQUENCE  {
   //       algorithm            AlgorithmIdentifier,
   //       subjectPublicKey     BIT STRING  }
-  bool VerifyInit(const uint8* signature_algorithm,
+  bool VerifyInit(const uint8_t* signature_algorithm,
                   int signature_algorithm_len,
-                  const uint8* signature,
+                  const uint8_t* signature,
                   int signature_len,
-                  const uint8* public_key_info,
+                  const uint8_t* public_key_info,
                   int public_key_info_len);
 
   // Feeds a piece of the data to the signature verifier.
-  void VerifyUpdate(const uint8* data_part, int data_part_len);
+  void VerifyUpdate(const uint8_t* data_part, int data_part_len);
 
   // Concludes a signature verification operation.  Returns true if the
   // signature is valid.  Returns false if the signature is invalid or an
   // error occurred.
   bool VerifyFinal();
 
   // Note: we can provide a one-shot interface if there is interest:
-  //   bool Verify(const uint8* data,
+  //   bool Verify(const uint8_t* data,
   //               int data_len,
-  //               const uint8* signature_algorithm,
+  //               const uint8_t* signature_algorithm,
   //               int signature_algorithm_len,
-  //               const uint8* signature,
+  //               const uint8_t* signature,
   //               int signature_len,
-  //               const uint8* public_key_info,
+  //               const uint8_t* public_key_info,
   //               int public_key_info_len);
 
  private:
   void Reset();
 
-  std::vector<uint8> signature_;
+  std::vector<uint8_t> signature_;
 
 #if defined(OS_LINUX)
   VFYContext* vfy_context_;
 #elif defined(OS_MACOSX)
-  std::vector<uint8> public_key_info_;
+  std::vector<uint8_t> public_key_info_;
 
   CSSM_CSP_HANDLE csp_handle_;
 
   CSSM_CC_HANDLE sig_handle_;
 
   CSSM_KEY public_key_;
 #elif defined(OS_WIN)
   HCRYPTPROV provider_;
--- a/ipc/chromium/src/base/crypto/signature_verifier_mac.cc
+++ b/ipc/chromium/src/base/crypto/signature_verifier_mac.cc
@@ -18,17 +18,17 @@ void* AppMalloc(CSSM_SIZE size, void *al
 void AppFree(void* mem_ptr, void* alloc_ref) {
   free(mem_ptr);
 }
 
 void* AppRealloc(void* ptr, CSSM_SIZE size, void* alloc_ref) {
   return realloc(ptr, size);
 }
 
-void* AppCalloc(uint32 num, CSSM_SIZE size, void* alloc_ref) {
+void* AppCalloc(uint32_t num, CSSM_SIZE size, void* alloc_ref) {
   return calloc(num, size);
 }
 
 const CSSM_API_MEMORY_FUNCS mem_funcs = {
   AppMalloc,
   AppFree,
   AppRealloc,
   AppCalloc,
@@ -53,30 +53,30 @@ SignatureVerifier::SignatureVerifier() :
 SignatureVerifier::~SignatureVerifier() {
   Reset();
   if (csp_handle_) {
     CSSM_RETURN crtn = CSSM_ModuleDetach(csp_handle_);
     DCHECK(crtn == CSSM_OK);
   }
 }
 
-bool SignatureVerifier::VerifyInit(const uint8* signature_algorithm,
+bool SignatureVerifier::VerifyInit(const uint8_t* signature_algorithm,
                                    int signature_algorithm_len,
-                                   const uint8* signature,
+                                   const uint8_t* signature,
                                    int signature_len,
-                                   const uint8* public_key_info,
+                                   const uint8_t* public_key_info,
                                    int public_key_info_len) {
   signature_.assign(signature, signature + signature_len);
   public_key_info_.assign(public_key_info,
                           public_key_info + public_key_info_len);
 
   CSSM_ALGORITHMS key_alg = CSSM_ALGID_RSA;  // TODO(wtc): hardcoded.
 
   memset(&public_key_, 0, sizeof(public_key_));
-  public_key_.KeyData.Data = const_cast<uint8*>(&public_key_info_[0]);
+  public_key_.KeyData.Data = const_cast<uint8_t*>(&public_key_info_[0]);
   public_key_.KeyData.Length = public_key_info_.size();
   public_key_.KeyHeader.HeaderVersion = CSSM_KEYHEADER_VERSION;
   public_key_.KeyHeader.BlobType = CSSM_KEYBLOB_RAW;
   public_key_.KeyHeader.Format = CSSM_KEYBLOB_RAW_FORMAT_X509;
   public_key_.KeyHeader.AlgorithmId = key_alg;
   public_key_.KeyHeader.KeyClass = CSSM_KEYCLASS_PUBLIC_KEY;
   public_key_.KeyHeader.KeyAttr = CSSM_KEYATTR_EXTRACTABLE;
   public_key_.KeyHeader.KeyUsage = CSSM_KEYUSE_VERIFY;
@@ -101,28 +101,28 @@ bool SignatureVerifier::VerifyInit(const
   crtn = CSSM_VerifyDataInit(sig_handle_);
   if (crtn) {
     NOTREACHED();
     return false;
   }
   return true;
 }
 
-void SignatureVerifier::VerifyUpdate(const uint8* data_part,
+void SignatureVerifier::VerifyUpdate(const uint8_t* data_part,
                                      int data_part_len) {
   CSSM_DATA data;
-  data.Data = const_cast<uint8*>(data_part);
+  data.Data = const_cast<uint8_t*>(data_part);
   data.Length = data_part_len;
   CSSM_RETURN crtn = CSSM_VerifyDataUpdate(sig_handle_, &data, 1);
   DCHECK(crtn == CSSM_OK);
 }
 
 bool SignatureVerifier::VerifyFinal() {
   CSSM_DATA sig;
-  sig.Data = const_cast<uint8*>(&signature_[0]);
+  sig.Data = const_cast<uint8_t*>(&signature_[0]);
   sig.Length = signature_.size();
   CSSM_RETURN crtn = CSSM_VerifyDataFinal(sig_handle_, &sig);
   Reset();
 
   // crtn is CSSMERR_CSP_VERIFY_FAILED if signature verification fails.
   return (crtn == CSSM_OK);
 }
 
--- a/ipc/chromium/src/base/crypto/signature_verifier_nss.cc
+++ b/ipc/chromium/src/base/crypto/signature_verifier_nss.cc
@@ -16,28 +16,28 @@ namespace base {
 SignatureVerifier::SignatureVerifier() : vfy_context_(NULL) {
   EnsureNSSInit();
 }
 
 SignatureVerifier::~SignatureVerifier() {
   Reset();
 }
 
-bool SignatureVerifier::VerifyInit(const uint8* signature_algorithm,
+bool SignatureVerifier::VerifyInit(const uint8_t* signature_algorithm,
                                    int signature_algorithm_len,
-                                   const uint8* signature,
+                                   const uint8_t* signature,
                                    int signature_len,
-                                   const uint8* public_key_info,
+                                   const uint8_t* public_key_info,
                                    int public_key_info_len) {
   signature_.assign(signature, signature + signature_len);
 
   CERTSubjectPublicKeyInfo* spki = NULL;
   SECItem spki_der;
   spki_der.type = siBuffer;
-  spki_der.data = const_cast<uint8*>(public_key_info);
+  spki_der.data = const_cast<uint8_t*>(public_key_info);
   spki_der.len = public_key_info_len;
   spki = SECKEY_DecodeDERSubjectPublicKeyInfo(&spki_der);
   if (!spki)
     return false;
   SECKEYPublicKey* public_key = SECKEY_ExtractPublicKey(spki);
   SECKEY_DestroySubjectPublicKeyInfo(spki);  // Done with spki.
   if (!public_key)
     return false;
@@ -45,31 +45,31 @@ bool SignatureVerifier::VerifyInit(const
   PLArenaPool* arena = PORT_NewArena(DER_DEFAULT_CHUNKSIZE);
   if (!arena) {
     SECKEY_DestroyPublicKey(public_key);
     return false;
   }
 
   SECItem sig_alg_der;
   sig_alg_der.type = siBuffer;
-  sig_alg_der.data = const_cast<uint8*>(signature_algorithm);
+  sig_alg_der.data = const_cast<uint8_t*>(signature_algorithm);
   sig_alg_der.len = signature_algorithm_len;
   SECAlgorithmID sig_alg_id;
   SECStatus rv;
   rv = SEC_QuickDERDecodeItem(arena, &sig_alg_id, SECOID_AlgorithmIDTemplate,
                               &sig_alg_der);
   if (rv != SECSuccess) {
     SECKEY_DestroyPublicKey(public_key);
     PORT_FreeArena(arena, PR_TRUE);
     return false;
   }
 
   SECItem sig;
   sig.type = siBuffer;
-  sig.data = const_cast<uint8*>(signature);
+  sig.data = const_cast<uint8_t*>(signature);
   sig.len = signature_len;
   SECOidTag hash_alg_tag;
   vfy_context_ = VFY_CreateContextWithAlgorithmID(public_key, &sig,
                                                   &sig_alg_id, &hash_alg_tag,
                                                   NULL);
   SECKEY_DestroyPublicKey(public_key);  // Done with public_key.
   PORT_FreeArena(arena, PR_TRUE);  // Done with sig_alg_id.
   if (!vfy_context_) {
@@ -82,17 +82,17 @@ bool SignatureVerifier::VerifyInit(const
   rv = VFY_Begin(vfy_context_);
   if (rv != SECSuccess) {
     NOTREACHED();
     return false;
   }
   return true;
 }
 
-void SignatureVerifier::VerifyUpdate(const uint8* data_part,
+void SignatureVerifier::VerifyUpdate(const uint8_t* data_part,
                                      int data_part_len) {
   SECStatus rv = VFY_Update(vfy_context_, data_part, data_part_len);
   DCHECK(rv == SECSuccess);
 }
 
 bool SignatureVerifier::VerifyFinal() {
   SECStatus rv = VFY_End(vfy_context_);
   Reset();
--- a/ipc/chromium/src/base/crypto/signature_verifier_unittest.cc
+++ b/ipc/chromium/src/base/crypto/signature_verifier_unittest.cc
@@ -17,17 +17,17 @@ TEST(SignatureVerifierTest, BasicTest) {
   //
   // The bytes in the array initializers are formatted to expose the DER
   // encoding of the ASN.1 structures.
 
   // The data that is signed is the following ASN.1 structure:
   //    TBSCertificate  ::=  SEQUENCE  {
   //        ...  -- omitted, not important
   //        }
-  const uint8 tbs_certificate[1017] = {
+  const uint8_t tbs_certificate[1017] = {
     0x30, 0x82, 0x03, 0xf5,  // a SEQUENCE of length 1013 (0x3f5)
     0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x03, 0x43, 0xdd, 0x63, 0x30, 0x0d,
     0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x05, 0x05,
     0x00, 0x30, 0x81, 0xca, 0x31, 0x0b, 0x30, 0x09, 0x06, 0x03, 0x55, 0x04,
     0x06, 0x13, 0x02, 0x55, 0x53, 0x31, 0x10, 0x30, 0x0e, 0x06, 0x03, 0x55,
     0x04, 0x08, 0x13, 0x07, 0x41, 0x72, 0x69, 0x7a, 0x6f, 0x6e, 0x61, 0x31,
     0x13, 0x30, 0x11, 0x06, 0x03, 0x55, 0x04, 0x07, 0x13, 0x0a, 0x53, 0x63,
     0x6f, 0x74, 0x74, 0x73, 0x64, 0x61, 0x6c, 0x65, 0x31, 0x1a, 0x30, 0x18,
@@ -111,26 +111,26 @@ TEST(SignatureVerifierTest, BasicTest) {
     0x74, 0x2e, 0x6f, 0x72, 0x67
   };
 
   // The signature algorithm is specified as the following ASN.1 structure:
   //    AlgorithmIdentifier  ::=  SEQUENCE  {
   //        algorithm               OBJECT IDENTIFIER,
   //        parameters              ANY DEFINED BY algorithm OPTIONAL  }
   //
-  const uint8 signature_algorithm[15] = {
+  const uint8_t signature_algorithm[15] = {
     0x30, 0x0d,  // a SEQUENCE of length 13 (0xd)
       0x06, 0x09,  // an OBJECT IDENTIFIER of length 9
         // 1.2.840.113549.1.1.5 - sha1WithRSAEncryption
         0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x05,
       0x05, 0x00,  // a NULL of length 0
   };
 
   // RSA signature, a big integer in the big-endian byte order.
-  const uint8 signature[256] = {
+  const uint8_t signature[256] = {
     0x1e, 0x6a, 0xe7, 0xe0, 0x4f, 0xe7, 0x4d, 0xd0, 0x69, 0x7c, 0xf8, 0x8f,
     0x99, 0xb4, 0x18, 0x95, 0x36, 0x24, 0x0f, 0x0e, 0xa3, 0xea, 0x34, 0x37,
     0xf4, 0x7d, 0xd5, 0x92, 0x35, 0x53, 0x72, 0x76, 0x3f, 0x69, 0xf0, 0x82,
     0x56, 0xe3, 0x94, 0x7a, 0x1d, 0x1a, 0x81, 0xaf, 0x9f, 0xc7, 0x43, 0x01,
     0x64, 0xd3, 0x7c, 0x0d, 0xc8, 0x11, 0x4e, 0x4a, 0xe6, 0x1a, 0xc3, 0x01,
     0x74, 0xe8, 0x35, 0x87, 0x5c, 0x61, 0xaa, 0x8a, 0x46, 0x06, 0xbe, 0x98,
     0x95, 0x24, 0x9e, 0x01, 0xe3, 0xe6, 0xa0, 0x98, 0xee, 0x36, 0x44, 0x56,
     0x8d, 0x23, 0x9c, 0x65, 0xea, 0x55, 0x6a, 0xdf, 0x66, 0xee, 0x45, 0xe8,
@@ -149,17 +149,17 @@ TEST(SignatureVerifierTest, BasicTest) {
     0x35, 0x52, 0xdd, 0x66, 0xde, 0x4f, 0x30, 0xc5, 0x73, 0x81, 0xb6, 0xe8,
     0x3c, 0xd8, 0x48, 0x8a
   };
 
   // The public key is specified as the following ASN.1 structure:
   //   SubjectPublicKeyInfo  ::=  SEQUENCE  {
   //       algorithm            AlgorithmIdentifier,
   //       subjectPublicKey     BIT STRING  }
-  const uint8 public_key_info[294] = {
+  const uint8_t public_key_info[294] = {
     0x30, 0x82, 0x01, 0x22,  // a SEQUENCE of length 290 (0x122)
       // algorithm
       0x30, 0x0d,  // a SEQUENCE of length 13
         0x06, 0x09,  // an OBJECT IDENTIFIER of length 9
           0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x01,
         0x05, 0x00,  // a NULL of length 0
       // subjectPublicKey
       0x03, 0x82, 0x01, 0x0f,  // a BIT STRING of length 271 (0x10f)
@@ -223,17 +223,17 @@ TEST(SignatureVerifierTest, BasicTest) {
   EXPECT_TRUE(ok);
   verifier.VerifyUpdate(tbs_certificate,       256);
   verifier.VerifyUpdate(tbs_certificate + 256, 256);
   verifier.VerifyUpdate(tbs_certificate + 512, sizeof(tbs_certificate) - 512);
   ok = verifier.VerifyFinal();
   EXPECT_TRUE(ok);
 
   // Test 3: verify the signature with incorrect data.
-  uint8 bad_tbs_certificate[sizeof(tbs_certificate)];
+  uint8_t bad_tbs_certificate[sizeof(tbs_certificate)];
   memcpy(bad_tbs_certificate, tbs_certificate, sizeof(tbs_certificate));
   bad_tbs_certificate[10] += 1;  // Corrupt one byte of the data.
   ok = verifier.VerifyInit(signature_algorithm,
                            sizeof(signature_algorithm),
                            signature, sizeof(signature),
                            public_key_info, sizeof(public_key_info));
   EXPECT_TRUE(ok);
   verifier.VerifyUpdate(bad_tbs_certificate, sizeof(bad_tbs_certificate));
@@ -243,17 +243,17 @@ TEST(SignatureVerifierTest, BasicTest) {
   // CryptoAPI function CryptVerifySignature to always succeed.  So we can't
   // check the signature verification results of the negative tests when
   // running inside Purify.  See http://crbug.com/10031.
 #ifndef PURIFY
   EXPECT_FALSE(ok);
 #endif
 
   // Test 4: verify a bad signature.
-  uint8 bad_signature[sizeof(signature)];
+  uint8_t bad_signature[sizeof(signature)];
   memcpy(bad_signature, signature, sizeof(signature));
   bad_signature[10] += 1;  // Corrupt one byte of the signature.
   ok = verifier.VerifyInit(signature_algorithm,
                            sizeof(signature_algorithm),
                            bad_signature, sizeof(bad_signature),
                            public_key_info, sizeof(public_key_info));
 
   // A crypto library (e.g., NSS) may detect that the signature is corrupted
--- a/ipc/chromium/src/base/crypto/signature_verifier_win.cc
+++ b/ipc/chromium/src/base/crypto/signature_verifier_win.cc
@@ -33,21 +33,21 @@ SignatureVerifier::SignatureVerifier() :
 SignatureVerifier::~SignatureVerifier() {
   Reset();
   if (provider_) {
     BOOL ok = CryptReleaseContext(provider_, 0);
     DCHECK(ok);
   }
 }
 
-bool SignatureVerifier::VerifyInit(const uint8* signature_algorithm,
+bool SignatureVerifier::VerifyInit(const uint8_t* signature_algorithm,
                                    int signature_algorithm_len,
-                                   const uint8* signature,
+                                   const uint8_t* signature,
                                    int signature_len,
-                                   const uint8* public_key_info,
+                                   const uint8_t* public_key_info,
                                    int public_key_info_len) {
   signature_.reserve(signature_len);
   // CryptoAPI uses big integers in the little-endian byte order, so we need
   // to first swap the order of signature bytes.
   for (int i = signature_len - 1; i >= 0; --i)
     signature_.push_back(signature[i]);
 
   CRYPT_DECODE_PARA decode_para;
@@ -109,17 +109,17 @@ bool SignatureVerifier::VerifyInit(const
   }
 
   ok = CryptCreateHash(provider_, hash_alg_id, 0, 0, &hash_object_);
   if (!ok)
     return false;
   return true;
 }
 
-void SignatureVerifier::VerifyUpdate(const uint8* data_part,
+void SignatureVerifier::VerifyUpdate(const uint8_t* data_part,
                                      int data_part_len) {
   BOOL ok = CryptHashData(hash_object_, data_part, data_part_len, 0);
   DCHECK(ok) << "CryptHashData failed: " << GetLastError();
 }
 
 bool SignatureVerifier::VerifyFinal() {
   BOOL ok = CryptVerifySignature(hash_object_, &signature_[0],
                                  signature_.size(), public_key_, NULL, 0);
--- a/ipc/chromium/src/base/data_pack.cc
+++ b/ipc/chromium/src/base/data_pack.cc
@@ -49,18 +49,18 @@ bool DataPack::Load(const FilePath& path
   mmap_.reset(new file_util::MemoryMappedFile);
   if (!mmap_->Initialize(path)) {
     mmap_.reset();
     return false;
   }
 
   // Parse the header of the file.
   // First uint32_t: version; second: resource count.
-  const uint32* ptr = reinterpret_cast<const uint32_t*>(mmap_->data());
-  uint32 version = ptr[0];
+  const uint32_t* ptr = reinterpret_cast<const uint32_t*>(mmap_->data());
+  uint32_t version = ptr[0];
   if (version != kFileFormatVersion) {
     LOG(ERROR) << "Bad data pack version: got " << version << ", expected "
                << kFileFormatVersion;
     mmap_.reset();
     return false;
   }
   resource_count_ = ptr[1];
 
--- a/ipc/chromium/src/base/file_util.cc
+++ b/ipc/chromium/src/base/file_util.cc
@@ -194,17 +194,17 @@ bool ReadFileToString(const FilePath& pa
 FILE* CreateAndOpenTemporaryFile(FilePath* path) {
   FilePath directory;
   if (!GetTempDir(&directory))
     return false;
 
   return CreateAndOpenTemporaryFileInDir(directory, path);
 }
 
-bool GetFileSize(const FilePath& file_path, int64* file_size) {
+bool GetFileSize(const FilePath& file_path, int64_t* file_size) {
   FileInfo info;
   if (!GetFileInfo(file_path, &info))
     return false;
   *file_size = info.size;
   return true;
 }
 
 bool CloseFile(FILE* file) {
@@ -374,17 +374,17 @@ bool GetFileInfo(const std::wstring& fil
   return GetFileInfo(FilePath::FromWStringHack(file_path), results);
 }
 std::wstring GetFilenameFromPath(const std::wstring& path) {
   if (path.empty() || EndsWithSeparator(path))
     return std::wstring();
 
   return FilePath::FromWStringHack(path).BaseName().ToWStringHack();
 }
-bool GetFileSize(const std::wstring& file_path, int64* file_size) {
+bool GetFileSize(const std::wstring& file_path, int64_t* file_size) {
   return GetFileSize(FilePath::FromWStringHack(file_path), file_size);
 }
 bool GetTempDir(std::wstring* path_str) {
   FilePath path;
   if (!GetTempDir(&path))
     return false;
   *path_str = path.ToWStringHack();
   return true;
--- a/ipc/chromium/src/base/file_util.h
+++ b/ipc/chromium/src/base/file_util.h
@@ -320,24 +320,24 @@ bool CreateNewTempDirectory(const std::w
 // Creates a directory, as well as creating any parent directories, if they
 // don't exist. Returns 'true' on successful creation, or if the directory
 // already exists.
 bool CreateDirectory(const FilePath& full_path);
 // Deprecated temporary compatibility function.
 bool CreateDirectory(const std::wstring& full_path);
 
 // Returns the file size. Returns true on success.
-bool GetFileSize(const FilePath& file_path, int64* file_size);
+bool GetFileSize(const FilePath& file_path, int64_t* file_size);
 // Deprecated temporary compatibility function.
-bool GetFileSize(const std::wstring& file_path, int64* file_size);
+bool GetFileSize(const std::wstring& file_path, int64_t* file_size);
 
 // Used to hold information about a given file path.  See GetFileInfo below.
 struct FileInfo {
   // The size of the file in bytes.  Undefined when is_directory is true.
-  int64 size;
+  int64_t size;
 
   // True if the file corresponds to a directory.
   bool is_directory;
 
   // Add additional fields here as needed.
 };
 
 // Returns information about the given file path.
@@ -484,17 +484,17 @@ class MemoryMappedFile {
 
   // Opens an existing file and maps it into memory. Access is restricted to
   // read only. If this object already points to a valid memory mapped file
   // then this method will fail and return false. If it cannot open the file,
   // the file does not exist, or the memory mapping fails, it will return false.
   // Later we may want to allow the user to specify access.
   bool Initialize(const FilePath& file_name);
 
-  const uint8* data() const { return data_; }
+  const uint8_t* data() const { return data_; }
   size_t length() const { return length_; }
 
   // Is file_ a valid file handle that points to an open, memory mapped file?
   bool IsValid();
 
  private:
   // Map the file to memory, set data_ to that memory address. Return true on
   // success, false on any kind of failure. This is a helper for Initialize().
@@ -505,17 +505,17 @@ class MemoryMappedFile {
 
 #if defined(OS_WIN)
   HANDLE file_;
   HANDLE file_mapping_;
 #elif defined(OS_POSIX)
   // The file descriptor.
   int file_;
 #endif
-  uint8* data_;
+  uint8_t* data_;
   size_t length_;
 
   DISALLOW_COPY_AND_ASSIGN(MemoryMappedFile);
 };
 
 // Renames a file using the SHFileOperation API to ensure that the target file
 // gets the correct default security descriptor in the new path.
 bool RenameFileAndResetSecurityDescriptor(
--- a/ipc/chromium/src/base/file_util_posix.cc
+++ b/ipc/chromium/src/base/file_util_posix.cc
@@ -713,17 +713,17 @@ bool MemoryMappedFile::MapFileToMemory(c
   if (file_ == -1)
     return false;
 
   struct stat file_stat;
   if (fstat(file_, &file_stat) == -1)
     return false;
   length_ = file_stat.st_size;
 
-  data_ = static_cast<uint8*>(
+  data_ = static_cast<uint8_t*>(
       mmap(NULL, length_, PROT_READ, MAP_SHARED, file_, 0));
   if (data_ == MAP_FAILED)
     data_ = NULL;
   return data_ != NULL;
 }
 
 void MemoryMappedFile::CloseHandles() {
   if (data_ != NULL)
--- a/ipc/chromium/src/base/file_util_unittest.cc
+++ b/ipc/chromium/src/base/file_util_unittest.cc
@@ -102,17 +102,17 @@ std::wstring ReadTextFile(const FilePath
   file.open(WideToUTF8(filename.ToWStringHack()).c_str());
   EXPECT_TRUE(file.is_open());
   file.getline(contents, 64);
   file.close();
   return std::wstring(contents);
 }
 
 #if defined(OS_WIN)
-uint64 FileTimeAsUint64(const FILETIME& ft) {
+uint64_t FileTimeAsUint64(const FILETIME& ft) {
   ULARGE_INTEGER u;
   u.LowPart = ft.dwLowDateTime;
   u.HighPart = ft.dwHighDateTime;
   return u.QuadPart;
 }
 #endif
 
 const struct append_case {
--- a/ipc/chromium/src/base/file_util_win.cc
+++ b/ipc/chromium/src/base/file_util_win.cc
@@ -483,17 +483,17 @@ bool CreateTemporaryFileNameInDir(const 
 
 bool CreateNewTempDirectory(const FilePath::StringType& prefix,
                             FilePath* new_temp_path) {
   FilePath system_temp_dir;
   if (!GetTempDir(&system_temp_dir))
     return false;
 
   FilePath path_to_create;
-  srand(static_cast<uint32>(time(NULL)));
+  srand(static_cast<uint32_t>(time(NULL)));
 
   int count = 0;
   while (count < 50) {
     // Try create a new temporary directory with random generated name. If
     // the one exists, keep trying another path name until we reach some limit.
     path_to_create = system_temp_dir;
     std::wstring new_dir_name;
     new_dir_name.assign(prefix);
@@ -774,17 +774,17 @@ bool MemoryMappedFile::MapFileToMemory(c
   if (length_ == INVALID_FILE_SIZE)
     return false;
 
   file_mapping_ = ::CreateFileMapping(file_, NULL, PAGE_READONLY,
                                       0, length_, NULL);
   if (file_mapping_ == INVALID_HANDLE_VALUE)
     return false;
 
-  data_ = static_cast<uint8*>(
+  data_ = static_cast<uint8_t*>(
       ::MapViewOfFile(file_mapping_, FILE_MAP_READ, 0, 0, length_));
   return data_ != NULL;
 }
 
 void MemoryMappedFile::CloseHandles() {
   if (data_)
     ::UnmapViewOfFile(data_);
   if (file_mapping_ != INVALID_HANDLE_VALUE)
--- a/ipc/chromium/src/base/file_version_info.cc
+++ b/ipc/chromium/src/base/file_version_info.cc
@@ -52,17 +52,17 @@ FileVersionInfo* FileVersionInfo::Create
     return NULL;
 
   if (!::GetFileVersionInfo(path, dummy, length, data)) {
     free(data);
     return NULL;
   }
 
   LanguageAndCodePage* translate = NULL;
-  uint32 page_count;
+  uint32_t page_count;
   BOOL query_result = VerQueryValue(data, L"\\VarFileInfo\\Translation",
                                    (void**) &translate, &page_count);
 
   if (query_result && translate) {
     return new FileVersionInfo(data, translate->language,
                                translate->code_page);
 
   } else {
@@ -161,17 +161,17 @@ bool FileVersionInfo::GetValue(const wch
   i = 0;
   while (i < arraysize(lang_codepage)) {
     wchar_t sub_block[MAX_PATH];
     WORD language = lang_codepage[i++];
     WORD code_page = lang_codepage[i++];
     _snwprintf_s(sub_block, MAX_PATH, MAX_PATH,
                  L"\\StringFileInfo\\%04x%04x\\%ls", language, code_page, name);
     LPVOID value = NULL;
-    uint32 size;
+    uint32_t size;
     BOOL r = ::VerQueryValue(data_.get(), sub_block, &value, &size);
     if (r && value) {
       value_str->assign(static_cast<wchar_t*>(value));
       return true;
     }
   }
   return false;
 }
--- a/ipc/chromium/src/base/histogram.cc
+++ b/ipc/chromium/src/base/histogram.cc
@@ -23,17 +23,17 @@ namespace base {
 
 #define DVLOG(x) LOG(ERROR)
 #define CHECK_GT DCHECK_GT
 #define CHECK_LT DCHECK_LT
 typedef ::Lock Lock;
 typedef ::AutoLock AutoLock;
 
 // Static table of checksums for all possible 8 bit bytes.
-const uint32 Histogram::kCrcTable[256] = {0x0, 0x77073096L, 0xee0e612cL,
+const uint32_t Histogram::kCrcTable[256] = {0x0, 0x77073096L, 0xee0e612cL,
 0x990951baL, 0x76dc419L, 0x706af48fL, 0xe963a535L, 0x9e6495a3L, 0xedb8832L,
 0x79dcb8a4L, 0xe0d5e91eL, 0x97d2d988L, 0x9b64c2bL, 0x7eb17cbdL, 0xe7b82d07L,
 0x90bf1d91L, 0x1db71064L, 0x6ab020f2L, 0xf3b97148L, 0x84be41deL, 0x1adad47dL,
 0x6ddde4ebL, 0xf4d4b551L, 0x83d385c7L, 0x136c9856L, 0x646ba8c0L, 0xfd62f97aL,
 0x8a65c9ecL, 0x14015c4fL, 0x63066cd9L, 0xfa0f3d63L, 0x8d080df5L, 0x3b6e20c8L,
 0x4c69105eL, 0xd56041e4L, 0xa2677172L, 0x3c03e4d1L, 0x4b04d447L, 0xd20d85fdL,
 0xa50ab56bL, 0x35b5a8faL, 0x42b2986cL, 0xdbbbc9d6L, 0xacbcf940L, 0x32d86ce3L,
 0x45df5c75L, 0xdcd60dcfL, 0xabd13d59L, 0x26d930acL, 0x51de003aL, 0xc8d75180L,
@@ -197,18 +197,18 @@ void Histogram::WriteAscii(bool graph_it
   for (size_t i = 0; i < bucket_count(); ++i) {
     if (snapshot.counts(i)) {
       size_t width = GetAsciiBucketRange(i).size() + 1;
       if (width > print_width)
         print_width = width;
     }
   }
 
-  int64 remaining = sample_count;
-  int64 past = 0;
+  int64_t remaining = sample_count;
+  int64_t past = 0;
   // Output the actual histogram graph.
   for (size_t i = 0; i < bucket_count(); ++i) {
     Count current = snapshot.counts(i);
     if (!current && !PrintEmptyBucket(i))
       continue;
     remaining -= current;
     std::string range = GetAsciiBucketRange(i);
     output->append(range);
@@ -256,17 +256,17 @@ bool Histogram::DeserializeHistogramInfo
   }
 
   Pickle pickle(histogram_info.data(),
                 static_cast<int>(histogram_info.size()));
   std::string histogram_name;
   int declared_min;
   int declared_max;
   size_t bucket_count;
-  uint32 range_checksum;
+  uint32_t range_checksum;
   int histogram_type;
   int pickle_flags;
   SampleSet sample;
 
   void* iter = NULL;
   if (!pickle.ReadString(&iter, &histogram_name) ||
       !pickle.ReadInt(&iter, &declared_min) ||
       !pickle.ReadInt(&iter, &declared_max) ||
@@ -327,29 +327,29 @@ bool Histogram::DeserializeHistogramInfo
 //------------------------------------------------------------------------------
 // Methods for the validating a sample and a related histogram.
 //------------------------------------------------------------------------------
 
 Histogram::Inconsistencies Histogram::FindCorruption(
     const SampleSet& snapshot) const {
   int inconsistencies = NO_INCONSISTENCIES;
   Sample previous_range = -1;  // Bottom range is always 0.
-  int64 count = 0;
+  int64_t count = 0;
   for (size_t index = 0; index < bucket_count(); ++index) {
     count += snapshot.counts(index);
     int new_range = ranges(index);
     if (previous_range >= new_range)
       inconsistencies |= BUCKET_ORDER_ERROR;
     previous_range = new_range;
   }
 
   if (!HasValidRangeChecksum())
     inconsistencies |= RANGE_CHECKSUM_ERROR;
 
-  int64 delta64 = snapshot.redundant_count() - count;
+  int64_t delta64 = snapshot.redundant_count() - count;
   if (delta64 != 0) {
     int delta = static_cast<int>(delta64);
     if (delta != delta64)
       delta = INT_MAX;  // Flag all giant errors as INT_MAX.
     // Since snapshots of histograms are taken asynchronously relative to
     // sampling (and snapped from different threads), it is pretty likely that
     // we'll catch a redundant count that doesn't match the sample count.  We
     // allow for a certain amount of slop before flagging this as an
@@ -554,19 +554,19 @@ bool Histogram::ValidateBucketRanges() c
   DCHECK_EQ(bucket_count_ + 1, ranges_.size());
   DCHECK_EQ(0, ranges_[0]);
   DCHECK_EQ(declared_min(), ranges_[1]);
   DCHECK_EQ(declared_max(), ranges_[bucket_count_ - 1]);
   DCHECK_EQ(kSampleType_MAX, ranges_[bucket_count_]);
   return true;
 }
 
-uint32 Histogram::CalculateRangeChecksum() const {
+uint32_t Histogram::CalculateRangeChecksum() const {
   DCHECK_EQ(ranges_.size(), bucket_count() + 1);
-  uint32 checksum = static_cast<uint32>(ranges_.size());  // Seed checksum.
+  uint32_t checksum = static_cast<uint32_t>(ranges_.size());  // Seed checksum.
   for (size_t index = 0; index < bucket_count(); ++index)
     checksum = Crc32(checksum, ranges(index));
   return checksum;
 }
 
 void Histogram::Initialize() {
   sample_.Resize(*this);
   if (declared_min_ < 1)
@@ -579,45 +579,45 @@ void Histogram::Initialize() {
   size_t maximal_bucket_count = declared_max_ - declared_min_ + 2;
   DCHECK_LE(bucket_count_, maximal_bucket_count);
   DCHECK_EQ(0, ranges_[0]);
   ranges_[bucket_count_] = kSampleType_MAX;
 }
 
 // We generate the CRC-32 using the low order bits to select whether to XOR in
 // the reversed polynomial 0xedb88320L.  This is nice and simple, and allows us
-// to keep the quotient in a uint32.  Since we're not concerned about the nature
+// to keep the quotient in a uint32_t.  Since we're not concerned about the nature
 // of corruptions (i.e., we don't care about bit sequencing, since we are
 // handling memory changes, which are more grotesque) so we don't bother to
 // get the CRC correct for big-endian vs little-ending calculations.  All we
 // need is a nice hash, that tends to depend on all the bits of the sample, with
 // very little chance of changes in one place impacting changes in another
 // place.
-uint32 Histogram::Crc32(uint32 sum, Histogram::Sample range) {
+uint32_t Histogram::Crc32(uint32_t sum, Histogram::Sample range) {
   const bool kUseRealCrc = true;  // TODO(jar): Switch to false and watch stats.
   if (kUseRealCrc) {
     union {
       Histogram::Sample range;
       unsigned char bytes[sizeof(Histogram::Sample)];
     } converter;
     converter.range = range;
     for (size_t i = 0; i < sizeof(converter); ++i)
       sum = kCrcTable[(sum & 0xff) ^ converter.bytes[i]] ^ (sum >> 8);
   } else {
     // Use hash techniques provided in ReallyFastHash, except we don't care
     // about "avalanching" (which would worsten the hash, and add collisions),
     // and we don't care about edge cases since we have an even number of bytes.
     union {
       Histogram::Sample range;
-      uint16 ints[sizeof(Histogram::Sample) / 2];
+      uint16_t ints[sizeof(Histogram::Sample) / 2];
     } converter;
     DCHECK_EQ(sizeof(Histogram::Sample), sizeof(converter));
     converter.range = range;
     sum += converter.ints[0];
-    sum = (sum << 16) ^ sum ^ (static_cast<uint32>(converter.ints[1]) << 11);
+    sum = (sum << 16) ^ sum ^ (static_cast<uint32_t>(converter.ints[1]) << 11);
     sum += sum >> 11;
   }
   return sum;
 }
 
 //------------------------------------------------------------------------------
 // Private methods
 
@@ -644,19 +644,19 @@ void Histogram::WriteAsciiHeader(const S
     double average = static_cast<float>(snapshot.sum()) / sample_count;
 
     StringAppendF(output, ", average = %.1f", average);
   }
   if (flags_ & ~kHexRangePrintingFlag)
     StringAppendF(output, " (flags = 0x%x)", flags_ & ~kHexRangePrintingFlag);
 }
 
-void Histogram::WriteAsciiBucketContext(const int64 past,
+void Histogram::WriteAsciiBucketContext(const int64_t past,
                                         const Count current,
-                                        const int64 remaining,
+                                        const int64_t remaining,
                                         const size_t i,
                                         std::string* output) const {
   double scaled_sum = (past + current + remaining) / 100.0;
   WriteAsciiBucketValue(current, scaled_sum, output);
   if (0 < i) {
     double percentage = past / scaled_sum;
     StringAppendF(output, " {%3.1f%%}", percentage);
   }
--- a/ipc/chromium/src/base/histogram.h
+++ b/ipc/chromium/src/base/histogram.h
@@ -329,48 +329,48 @@ class Histogram {
     void CheckSize(const Histogram& histogram) const;
 
     // Accessor for histogram to make routine additions.
     void Accumulate(Sample value, Count count, size_t index);
 
     // Accessor methods.
     Count counts(size_t i) const { return counts_[i]; }
     Count TotalCount() const;
-    int64 sum() const { return sum_; }
-    int64 redundant_count() const { return redundant_count_; }
+    int64_t sum() const { return sum_; }
+    int64_t redundant_count() const { return redundant_count_; }
     size_t size() const { return counts_.size(); }
 
     // Arithmetic manipulation of corresponding elements of the set.
     void Add(const SampleSet& other);
     void Subtract(const SampleSet& other);
 
     bool Serialize(Pickle* pickle) const;
     bool Deserialize(void** iter, const Pickle& pickle);
 
    protected:
     // Actual histogram data is stored in buckets, showing the count of values
     // that fit into each bucket.
     Counts counts_;
 
     // Save simple stats locally.  Note that this MIGHT get done in base class
     // without shared memory at some point.
-    int64 sum_;         // sum of samples.
+    int64_t sum_;         // sum of samples.
 
    private:
     // Allow tests to corrupt our innards for testing purposes.
     FRIEND_TEST(HistogramTest, CorruptSampleCounts);
 
     // To help identify memory corruption, we reduntantly save the number of
     // samples we've accumulated into all of our buckets.  We can compare this
     // count to the sum of the counts in all buckets, and detect problems.  Note
     // that due to races in histogram accumulation (if a histogram is indeed
     // updated on several threads simultaneously), the tallies might mismatch,
     // and also the snapshotting code may asynchronously get a mismatch (though
     // generally either race based mismatch cause is VERY rare).
-    int64 redundant_count_;
+    int64_t redundant_count_;
   };
 
   //----------------------------------------------------------------------------
   // minimum should start from 1. 0 is invalid as a minimum. 0 is an implicit
   // default underflow bucket.
   static Histogram* FactoryGet(const std::string& name,
                                Sample minimum,
                                Sample maximum,
@@ -437,17 +437,17 @@ class Histogram {
   //----------------------------------------------------------------------------
   // Accessors for factory constuction, serialization and testing.
   //----------------------------------------------------------------------------
   virtual ClassType histogram_type() const;
   const std::string& histogram_name() const { return histogram_name_; }
   Sample declared_min() const { return declared_min_; }
   Sample declared_max() const { return declared_max_; }
   virtual Sample ranges(size_t i) const;
-  uint32 range_checksum() const { return range_checksum_; }
+  uint32_t range_checksum() const { return range_checksum_; }
   virtual size_t bucket_count() const;
   // Snapshot the current complete set of sample data.
   // Override with atomic/locked snapshot if needed.
   virtual void SnapshotSample(SampleSet* sample) const;
 
   virtual bool HasConstructorArguments(Sample minimum, Sample maximum,
                                        size_t bucket_count);
 
@@ -497,61 +497,61 @@ class Histogram {
   // Accessors for derived classes.
   //----------------------------------------------------------------------------
   void SetBucketRange(size_t i, Sample value);
 
   // Validate that ranges_ was created sensibly (top and bottom range
   // values relate properly to the declared_min_ and declared_max_)..
   bool ValidateBucketRanges() const;
 
-  virtual uint32 CalculateRangeChecksum() const;
+  virtual uint32_t CalculateRangeChecksum() const;
 
  private:
   // Allow tests to corrupt our innards for testing purposes.
   FRIEND_TEST(HistogramTest, CorruptBucketBounds);
   FRIEND_TEST(HistogramTest, CorruptSampleCounts);
   FRIEND_TEST(HistogramTest, Crc32SampleHash);
   FRIEND_TEST(HistogramTest, Crc32TableTest);
 
   friend class StatisticsRecorder;  // To allow it to delete duplicates.
 
   // Post constructor initialization.
   void Initialize();
 
   // Checksum function for accumulating range values into a checksum.
-  static uint32 Crc32(uint32 sum, Sample range);
+  static uint32_t Crc32(uint32_t sum, Sample range);
 
   //----------------------------------------------------------------------------
   // Helpers for emitting Ascii graphic.  Each method appends data to output.
 
   // Find out how large the (graphically) the largest bucket will appear to be.
   double GetPeakBucketSize(const SampleSet& snapshot) const;
 
   // Write a common header message describing this histogram.
   void WriteAsciiHeader(const SampleSet& snapshot,
                         Count sample_count, std::string* output) const;
 
   // Write information about previous, current, and next buckets.
   // Information such as cumulative percentage, etc.
-  void WriteAsciiBucketContext(const int64 past, const Count current,
-                               const int64 remaining, const size_t i,
+  void WriteAsciiBucketContext(const int64_t past, const Count current,
+                               const int64_t remaining, const size_t i,
                                std::string* output) const;
 
   // Write textual description of the bucket contents (relative to histogram).
   // Output is the count in the buckets, as well as the percentage.
   void WriteAsciiBucketValue(Count current, double scaled_sum,
                              std::string* output) const;
 
   // Produce actual graph (set of blank vs non blank char's) for a bucket.
   void WriteAsciiBucketGraph(double current_size, double max_size,
                              std::string* output) const;
 
   //----------------------------------------------------------------------------
   // Table for generating Crc32 values.
-  static const uint32 kCrcTable[256];
+  static const uint32_t kCrcTable[256];
   //----------------------------------------------------------------------------
   // Invariant values set at/near construction time
 
   // ASCII version of original name given to the constructor.  All identically
   // named instances will be coalesced cross-project.
   const std::string histogram_name_;
   Sample declared_min_;  // Less than this goes into counts_[0]
   Sample declared_max_;  // Over this goes into counts_[bucket_count_ - 1].
@@ -564,17 +564,17 @@ class Histogram {
   // corresponding bucket. We also append one extra element in this array,
   // containing kSampleType_MAX, to make calculations easy.
   // The dimension of ranges_ is bucket_count + 1.
   Ranges ranges_;
 
   // For redundancy, we store a checksum of all the sample ranges when ranges
   // are generated.  If ever there is ever a difference, then the histogram must
   // have been corrupted.
-  uint32 range_checksum_;
+  uint32_t range_checksum_;
 
   // Finally, provide the state that changes with the addition of each new
   // sample.
   SampleSet sample_;
 
   DISALLOW_COPY_AND_ASSIGN(Histogram);
 };
 
--- a/ipc/chromium/src/base/histogram_unittest.cc
+++ b/ipc/chromium/src/base/histogram_unittest.cc
@@ -382,19 +382,19 @@ TEST(HistogramTest, CorruptBucketBounds)
   --histogram->ranges_[3];
   ++histogram->ranges_[4];
 }
 
 // Table was generated similarly to sample code for CRC-32 given on:
 // http://www.w3.org/TR/PNG/#D-CRCAppendix.
 TEST(HistogramTest, Crc32TableTest) {
   for (int i = 0; i < 256; ++i) {
-    uint32 checksum = i;
+    uint32_t checksum = i;
     for (int j = 0; j < 8; ++j) {
-      const uint32 kReversedPolynomial = 0xedb88320L;
+      const uint32_t kReversedPolynomial = 0xedb88320L;
       if (checksum & 1)
         checksum = kReversedPolynomial ^ (checksum >> 1);
       else
         checksum >>= 1;
     }
     EXPECT_EQ(Histogram::kCrcTable[i], checksum);
   }
 }
--- a/ipc/chromium/src/base/id_map.h
+++ b/ipc/chromium/src/base/id_map.h
@@ -15,17 +15,17 @@
 // item in the list).
 //
 // Items can be inserted into the container with arbitrary ID, but the caller
 // must ensure they are unique. Inserting IDs and relying on automatically
 // generated ones is not allowed because they can collide.
 template<class T>
 class IDMap {
  private:
-  typedef base::hash_map<int32, T*> HashTable;
+  typedef base::hash_map<int32_t, T*> HashTable;
   typedef typename HashTable::iterator iterator;
 
  public:
   // support const iterators over the items
   // Note, use iterator->first to get the ID, iterator->second to get the T*
   typedef typename HashTable::const_iterator const_iterator;
 
   IDMap() : next_id_(1) {
@@ -37,34 +37,34 @@ class IDMap {
   const_iterator begin() const {
     return data_.begin();
   }
   const_iterator end() const {
     return data_.end();
   }
 
   // Adds a view with an automatically generated unique ID. See AddWithID.
-  int32 Add(T* data) {
-    int32 this_id = next_id_;
+  int32_t Add(T* data) {
+    int32_t this_id = next_id_;
     DCHECK(data_.find(this_id) == data_.end()) << "Inserting duplicate item";
     data_[this_id] = data;
     next_id_++;
     return this_id;
   }
 
   // Adds a new data member with the specified ID. The ID must not be in
   // the list. The caller either must generate all unique IDs itself and use
   // this function, or allow this object to generate IDs and call Add. These
   // two methods may not be mixed, or duplicate IDs may be generated
-  void AddWithID(T* data, int32 id) {
+  void AddWithID(T* data, int32_t id) {
     DCHECK(data_.find(id) == data_.end()) << "Inserting duplicate item";
     data_[id] = data;
   }
 
-  void Remove(int32 id) {
+  void Remove(int32_t id) {
     iterator i = data_.find(id);
     if (i == data_.end()) {
       NOTREACHED() << "Attempting to remove an item not in the list";
       return;
     }
     data_.erase(i);
   }
 
@@ -79,27 +79,27 @@ class IDMap {
   bool HasData(const T* data) const {
     // XXX would like to use <algorithm> here ...
     for (const_iterator it = begin(); it != end(); ++it)
       if (data == it->second)
         return true;
     return false;
   }
 
-  T* Lookup(int32 id) const {
+  T* Lookup(int32_t id) const {
     const_iterator i = data_.find(id);
     if (i == data_.end())
       return NULL;
     return i->second;
   }
 
   size_t size() const {
     return data_.size();
   }
 
  protected:
   // The next ID that we will return from Add()
-  int32 next_id_;
+  int32_t next_id_;
 
   HashTable data_;
 };
 
 #endif  // BASE_ID_MAP_H__
--- a/ipc/chromium/src/base/idle_timer.cc
+++ b/ipc/chromium/src/base/idle_timer.cc
@@ -23,36 +23,36 @@
 #endif
 
 #include "base/message_loop.h"
 #include "base/time.h"
 
 namespace base {
 
 #if defined(OS_WIN)
-bool OSIdleTimeSource(int32 *milliseconds_interval_since_last_event) {
+bool OSIdleTimeSource(int32_t *milliseconds_interval_since_last_event) {
   LASTINPUTINFO lastInputInfo;
   lastInputInfo.cbSize = sizeof(lastInputInfo);
   if (GetLastInputInfo(&lastInputInfo) == 0) {
     return false;
   }
-  int32 last_input_time = lastInputInfo.dwTime;
+  int32_t last_input_time = lastInputInfo.dwTime;
 
   // Note: On Windows GetLastInputInfo returns a 32bit value which rolls over
   // ~49days.
-  int32 current_time = GetTickCount();
-  int32 delta = current_time - last_input_time;
+  int32_t current_time = GetTickCount();
+  int32_t delta = current_time - last_input_time;
   // delta will go negative if we've been idle for 2GB of ticks.
   if (delta < 0)
     delta = -delta;
   *milliseconds_interval_since_last_event = delta;
   return true;
 }
 #elif defined(OS_MACOSX)
-bool OSIdleTimeSource(int32 *milliseconds_interval_since_last_event) {
+bool OSIdleTimeSource(int32_t *milliseconds_interval_since_last_event) {
   *milliseconds_interval_since_last_event =
       CGEventSourceSecondsSinceLastEventType(
           kCGEventSourceStateCombinedSessionState,
           kCGAnyInputEventType) * 1000.0;
   return true;
 }
 #elif defined(OS_LINUX) && ENABLE_XSS_SUPPORT
 class IdleState {
@@ -67,36 +67,36 @@ class IdleState {
 
   ~IdleState() {
     if (idle_info_.Get()) {
       XFree(idle_info_.Get());
       idle_info_.~ThreadLocalPointer();
     }
   }
 
-  int32 IdleTime() {
+  int32_t IdleTime() {
     if (have_idle_info_ && idle_info_.Get()) {
       XScreenSaverQueryInfo(GDK_DISPLAY(), GDK_ROOT_WINDOW(),
                             idle_info_.Get());
       return idle_info_.Get()->idle;
     }
     return -1;
   }
 
  private:
   bool have_idle_info_;
   ThreadLocalPointer<XScreenSaverInfo> idle_info_;
 
   DISALLOW_COPY_AND_ASSIGN(IdleState);
 };
 
-bool OSIdleTimeSource(int32* milliseconds_interval_since_last_event) {
+bool OSIdleTimeSource(int32_t* milliseconds_interval_since_last_event) {
   static LazyInstance<IdleState> state_instance(base::LINKER_INITIALIZED);
   IdleState* state = state_instance.Pointer();
-  int32 idle_time = state->IdleTime();
+  int32_t idle_time = state->IdleTime();
   if (0 < idle_time) {
     *milliseconds_interval_since_last_event = idle_time;
     return true;
   }
   return false;
 }
 #endif
 
@@ -134,17 +134,17 @@ void IdleTimer::StartTimer() {
   DCHECK(!timer_.IsRunning());
   TimeDelta delay = TimeUntilIdle();
   if (delay.InMilliseconds() < 0)
     delay = TimeDelta();
   timer_.Start(delay, this, &IdleTimer::Run);
 }
 
 TimeDelta IdleTimer::CurrentIdleTime() {
-  int32 interval = 0;
+  int32_t interval = 0;
   if (idle_time_source_(&interval)) {
     return TimeDelta::FromMilliseconds(interval);
   }
   NOTREACHED();
   return TimeDelta::FromMilliseconds(0);
 }
 
 TimeDelta IdleTimer::TimeUntilIdle() {
--- a/ipc/chromium/src/base/idle_timer.h
+++ b/ipc/chromium/src/base/idle_timer.h
@@ -35,17 +35,17 @@
 #include "base/basictypes.h"
 #include "base/task.h"
 #include "base/timer.h"
 
 namespace base {
 
 // Function prototype - Get the number of milliseconds that the user has been
 // idle.
-typedef bool (*IdleTimeSource)(int32 *milliseconds_interval_since_last_event);
+typedef bool (*IdleTimeSource)(int32_t *milliseconds_interval_since_last_event);
 
 class IdleTimer {
  public:
   // Create an IdleTimer.
   // idle_time: idle time required before this timer can run.
   // repeat: true if the timer should fire multiple times per idle,
   //         false to fire once per idle.
   IdleTimer(TimeDelta idle_time, bool repeat);
--- a/ipc/chromium/src/base/idletimer_unittest.cc
+++ b/ipc/chromium/src/base/idletimer_unittest.cc
@@ -18,20 +18,20 @@ using base::IdleTimer;
 const int kSafeTestIntervalMs = 500;
 
 namespace {
 
 // We Mock the GetLastInputInfo function to return
 // the time stored here.
 static Time mock_timer_started;
 
-bool MockIdleTimeSource(int32 *milliseconds_interval_since_last_event) {
+bool MockIdleTimeSource(int32_t *milliseconds_interval_since_last_event) {
   TimeDelta delta = Time::Now() - mock_timer_started;
   *milliseconds_interval_since_last_event =
-      static_cast<int32>(delta.InMilliseconds());
+      static_cast<int32_t>(delta.InMilliseconds());
   return true;
 }
 
 // TestIdle task fires after 100ms of idle time.
 class TestIdleTask : public IdleTimer {
  public:
   TestIdleTask(bool repeat)
       : IdleTimer(TimeDelta::FromMilliseconds(kSafeTestIntervalMs), repeat),
--- a/ipc/chromium/src/base/lazy_instance.h
+++ b/ipc/chromium/src/base/lazy_instance.h
@@ -95,16 +95,16 @@ class LazyInstance : public LazyInstance
     // We will hopefully have fast access when the instance is already created.
     if (base::subtle::NoBarrier_Load(&state_) != STATE_CREATED)
       EnsureInstance(instance, Traits::New, Traits::Delete);
 
     return instance;
   }
 
  private:
-  int8 buf_[sizeof(Type)];  // Preallocate the space for the Type instance.
+  int8_t buf_[sizeof(Type)];  // Preallocate the space for the Type instance.
 
   DISALLOW_COPY_AND_ASSIGN(LazyInstance);
 };
 
 }  // namespace base
 
 #endif  // BASE_LAZY_INSTANCE_H_
--- a/ipc/chromium/src/base/lock_impl.h
+++ b/ipc/chromium/src/base/lock_impl.h
@@ -61,17 +61,17 @@ class LockImpl {
 
  private:
   OSLockType os_lock_;
 
 #if !defined(NDEBUG) && defined(OS_WIN)
   // All private data is implicitly protected by lock_.
   // Be VERY careful to only access members under that lock.
   PlatformThreadId owning_thread_id_;
-  int32 recursion_count_shadow_;
+  int32_t recursion_count_shadow_;
   bool recursion_used_;      // Allow debugging to continued after a DCHECK().
 #endif  // NDEBUG
 
   DISALLOW_COPY_AND_ASSIGN(LockImpl);
 };
 
 
 #endif  // BASE_LOCK_IMPL_H_
--- a/ipc/chromium/src/base/md5.cc
+++ b/ipc/chromium/src/base/md5.cc
@@ -20,30 +20,30 @@
 
 #include <string>
 
 #include "base/md5.h"
 
 #include "base/basictypes.h"
 
 struct Context {
-  uint32 buf[4];
-  uint32 bits[2];
+  uint32_t buf[4];
+  uint32_t bits[2];
   unsigned char in[64];
 };
 
 /*
  * Note: this code is harmless on little-endian machines.
  */
 static void byteReverse (unsigned char *buf, unsigned longs){
-        uint32 t;
+        uint32_t t;
         do {
-                t = (uint32)((unsigned)buf[3]<<8 | buf[2]) << 16 |
+                t = (uint32_t)((unsigned)buf[3]<<8 | buf[2]) << 16 |
                             ((unsigned)buf[1]<<8 | buf[0]);
-                *(uint32 *)buf = t;
+                *(uint32_t *)buf = t;
                 buf += 4;
         } while (--longs);
 }
 /* The four core functions - F1 is optimized somewhat */
 
 /* #define F1(x, y, z) (x & y | ~x & z) */
 #define F1(x, y, z) (z ^ (x & (y ^ z)))
 #define F2(x, y, z) F1(z, x, y)
@@ -54,18 +54,18 @@ static void byteReverse (unsigned char *
 #define MD5STEP(f, w, x, y, z, data, s) \
         ( w += f(x, y, z) + data,  w = w<<s | w>>(32-s),  w += x )
 
 /*
  * The core of the MD5 algorithm, this alters an existing MD5 hash to
  * reflect the addition of 16 longwords of new data.  MD5Update blocks
  * the data and converts bytes into longwords for this routine.
  */
-static void MD5Transform(uint32 buf[4], const uint32 in[16]){
-        register uint32 a, b, c, d;
+static void MD5Transform(uint32_t buf[4], const uint32_t in[16]){
+        register uint32_t a, b, c, d;
 
         a = buf[0];
         b = buf[1];
         c = buf[2];
         d = buf[3];
 
         MD5STEP(F1, a, b, c, d, in[ 0]+0xd76aa478,  7);
         MD5STEP(F1, d, a, b, c, in[ 1]+0xe8c7b756, 12);
@@ -157,50 +157,50 @@ void MD5Init(MD5Context *pCtx){
 
 /*
  * Update context to reflect the concatenation of another buffer full
  * of bytes.
  */
 void MD5Update(MD5Context *pCtx, const void *inbuf, size_t len){
         struct Context *ctx = (struct Context *)pCtx;
         const unsigned char* buf = (const unsigned char*)inbuf;
-        uint32 t;
+        uint32_t t;
 
         /* Update bitcount */
 
         t = ctx->bits[0];
-        if ((ctx->bits[0] = t + ((uint32)len << 3)) < t)
+        if ((ctx->bits[0] = t + ((uint32_t)len << 3)) < t)
                 ctx->bits[1]++; /* Carry from low to high */
-        ctx->bits[1] += static_cast<uint32>(len >> 29);
+        ctx->bits[1] += static_cast<uint32_t>(len >> 29);
 
         t = (t >> 3) & 0x3f;    /* Bytes already in shsInfo->data */
 
         /* Handle any leading odd-sized chunks */
 
         if ( t ) {
                 unsigned char *p = (unsigned char *)ctx->in + t;
 
                 t = 64-t;
                 if (len < t) {
                         memcpy(p, buf, len);
                         return;
                 }
                 memcpy(p, buf, t);
                 byteReverse(ctx->in, 16);
-                MD5Transform(ctx->buf, (uint32 *)ctx->in);
+                MD5Transform(ctx->buf, (uint32_t *)ctx->in);
                 buf += t;
                 len -= t;
         }
 
         /* Process data in 64-byte chunks */
 
         while (len >= 64) {
                 memcpy(ctx->in, buf, 64);
                 byteReverse(ctx->in, 16);
-                MD5Transform(ctx->buf, (uint32 *)ctx->in);
+                MD5Transform(ctx->buf, (uint32_t *)ctx->in);
                 buf += 64;
                 len -= 64;
         }
 
         /* Handle any remaining bytes of data. */
 
         memcpy(ctx->in, buf, len);
 }
@@ -225,31 +225,31 @@ void MD5Final(MD5Digest* digest, MD5Cont
         /* Bytes of padding needed to make 64 bytes */
         count = 64 - 1 - count;
 
         /* Pad out to 56 mod 64 */
         if (count < 8) {
                 /* Two lots of padding:  Pad the first block to 64 bytes */
                 memset(p, 0, count);
                 byteReverse(ctx->in, 16);
-                MD5Transform(ctx->buf, (uint32 *)ctx->in);
+                MD5Transform(ctx->buf, (uint32_t *)ctx->in);
 
                 /* Now fill the next block with 56 bytes */
                 memset(ctx->in, 0, 56);
         } else {
                 /* Pad block to 56 bytes */
                 memset(p, 0, count-8);
         }
         byteReverse(ctx->in, 14);
 
         /* Append length in bits and transform */
-        ((uint32 *)ctx->in)[ 14 ] = ctx->bits[0];
-        ((uint32 *)ctx->in)[ 15 ] = ctx->bits[1];
+        ((uint32_t *)ctx->in)[ 14 ] = ctx->bits[0];
+        ((uint32_t *)ctx->in)[ 15 ] = ctx->bits[1];
 
-        MD5Transform(ctx->buf, (uint32 *)ctx->in);
+        MD5Transform(ctx->buf, (uint32_t *)ctx->in);
         byteReverse((unsigned char *)ctx->buf, 4);
         memcpy(digest->a, ctx->buf, 16);
         memset(ctx, 0, sizeof(ctx));    /* In case it's sensitive */
 }
 
 std::string MD5DigestToBase16(const MD5Digest& digest){
   static char const zEncode[] = "0123456789abcdef";
 
--- a/ipc/chromium/src/base/message_pump_qt.cc
+++ b/ipc/chromium/src/base/message_pump_qt.cc
@@ -71,17 +71,17 @@ MessagePumpQt::scheduleDelayedIfNeeded(c
     return;
   }
 
   if (mTimer->isActive()) {
     mTimer->stop();
   }
 
   TimeDelta later = delayed_work_time - Time::Now();
-  // later.InMilliseconds() returns an int64, QTimer only accepts int's for start(),
+  // later.InMilliseconds() returns an int64_t, QTimer only accepts int's for start(),
   // std::min only works on exact same types.
   int laterMsecs = later.InMilliseconds() > std::numeric_limits<int>::max() ?
     std::numeric_limits<int>::max() : later.InMilliseconds();
   mTimer->start(laterMsecs > 0 ? laterMsecs : 0);
 }
 
 void
 MessagePumpQt::dispatchDelayed()
--- a/ipc/chromium/src/base/pickle.cc
+++ b/ipc/chromium/src/base/pickle.cc
@@ -10,57 +10,57 @@
 #include <string>
 
 //------------------------------------------------------------------------------
 
 // static
 const int Pickle::kPayloadUnit = 64;
 
 // We mark a read only pickle with a special capacity_.
-static const uint32 kCapacityReadOnly = (uint32) -1;
+static const uint32_t kCapacityReadOnly = (uint32_t) -1;
 
 static const char kBytePaddingMarker = char(0xbf);
 
-// Payload is uint32 aligned.
+// Payload is uint32_t aligned.
 
 Pickle::Pickle()
     : header_(NULL),
       header_size_(sizeof(Header)),
       capacity_(0),
       variable_buffer_offset_(0) {
   Resize(kPayloadUnit);
   header_->payload_size = 0;
 }
 
 Pickle::Pickle(int header_size)
     : header_(NULL),
-      header_size_(AlignInt(header_size, sizeof(uint32))),
+      header_size_(AlignInt(header_size, sizeof(uint32_t))),
       capacity_(0),
       variable_buffer_offset_(0) {
-  DCHECK(static_cast<uint32>(header_size) >= sizeof(Header));
+  DCHECK(static_cast<uint32_t>(header_size) >= sizeof(Header));
   DCHECK(header_size <= kPayloadUnit);
   Resize(kPayloadUnit);
   header_->payload_size = 0;
 }
 
 Pickle::Pickle(const char* data, int data_len)
     : header_(reinterpret_cast<Header*>(const_cast<char*>(data))),
       header_size_(data_len - header_->payload_size),
       capacity_(kCapacityReadOnly),
       variable_buffer_offset_(0) {
   DCHECK(header_size_ >= sizeof(Header));
-  DCHECK(header_size_ == AlignInt(header_size_, sizeof(uint32)));
+  DCHECK(header_size_ == AlignInt(header_size_, sizeof(uint32_t)));
 }
 
 Pickle::Pickle(const Pickle& other)
     : header_(NULL),
       header_size_(other.header_size_),
       capacity_(0),
       variable_buffer_offset_(other.variable_buffer_offset_) {
-  uint32 payload_size = header_size_ + other.header_->payload_size;
+  uint32_t payload_size = header_size_ + other.header_->payload_size;
   bool resized = Resize(payload_size);
   CHECK(resized);  // Realloc failed.
   memcpy(header_, other.header_, payload_size);
 }
 
 Pickle::~Pickle() {
   if (capacity_ != kCapacityReadOnly)
     free(header_);
@@ -85,31 +85,31 @@ bool Pickle::ReadBool(void** iter, bool*
   int tmp;
   if (!ReadInt(iter, &tmp))
     return false;
   DCHECK(0 == tmp || 1 == tmp);
   *result = tmp ? true : false;
   return true;
 }
 
-bool Pickle::ReadInt16(void** iter, int16* result) const {
+bool Pickle::ReadInt16(void** iter, int16_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
 
   UpdateIter(iter, sizeof(*result));
   return true;
 }
 
-bool Pickle::ReadUInt16(void** iter, uint16* result) const {
+bool Pickle::ReadUInt16(void** iter, uint16_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
@@ -137,17 +137,17 @@ bool Pickle::ReadInt(void** iter, int* r
 
 // Always written as a 64-bit value since the size for this type can
 // differ between architectures.
 bool Pickle::ReadLong(void** iter, long* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
-  int64 bigResult = 0;
+  int64_t bigResult = 0;
   if (!IteratorHasRoomFor(*iter, sizeof(bigResult)))
     return false;
 
   // TODO(jar) bug 1129285: Pickle should be cleaned up, and not dependent on
   // alignment.
   memcpy(&bigResult, *iter, sizeof(bigResult));
   DCHECK(bigResult <= LONG_MAX && bigResult >= LONG_MIN);
   *result = static_cast<long>(bigResult);
@@ -158,17 +158,17 @@ bool Pickle::ReadLong(void** iter, long*
 
 // Always written as a 64-bit value since the size for this type can
 // differ between architectures.
 bool Pickle::ReadULong(void** iter, unsigned long* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
-  uint64 bigResult = 0;
+  uint64_t bigResult = 0;
   if (!IteratorHasRoomFor(*iter, sizeof(bigResult)))
     return false;
 
   // TODO(jar) bug 1129285: Pickle should be cleaned up, and not dependent on
   // alignment.
   memcpy(&bigResult, *iter, sizeof(bigResult));
   DCHECK(bigResult <= ULONG_MAX);
   *result = static_cast<unsigned long>(bigResult);
@@ -185,73 +185,73 @@ bool Pickle::ReadLength(void** iter, int
 
 // Always written as a 64-bit value since the size for this type can
 // differ between architectures.
 bool Pickle::ReadSize(void** iter, size_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
-  uint64 bigResult = 0;
+  uint64_t bigResult = 0;
   if (!IteratorHasRoomFor(*iter, sizeof(bigResult)))
     return false;
 
   // TODO(jar) bug 1129285: Pickle should be cleaned up, and not dependent on
   // alignment.
   memcpy(&bigResult, *iter, sizeof(bigResult));
   DCHECK(bigResult <= std::numeric_limits<size_t>::max());
   *result = static_cast<size_t>(bigResult);
 
   UpdateIter(iter, sizeof(bigResult));
   return true;
 }
 
-bool Pickle::ReadInt32(void** iter, int32* result) const {
+bool Pickle::ReadInt32(void** iter, int32_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
 
   UpdateIter(iter, sizeof(*result));
   return true;
 }
 
-bool Pickle::ReadUInt32(void** iter, uint32* result) const {
+bool Pickle::ReadUInt32(void** iter, uint32_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
 
   UpdateIter(iter, sizeof(*result));
   return true;
 }
 
-bool Pickle::ReadInt64(void** iter, int64* result) const {
+bool Pickle::ReadInt64(void** iter, int64_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
 
   UpdateIter(iter, sizeof(*result));
   return true;
 }
 
-bool Pickle::ReadUInt64(void** iter, uint64* result) const {
+bool Pickle::ReadUInt64(void** iter, uint64_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
   if (!IteratorHasRoomFor(*iter, sizeof(*result)))
     return false;
 
   memcpy(result, *iter, sizeof(*result));
@@ -276,17 +276,17 @@ bool Pickle::ReadDouble(void** iter, dou
 
 // Always written as a 64-bit value since the size for this type can
 // differ between architectures.
 bool Pickle::ReadIntPtr(void** iter, intptr_t* result) const {
   DCHECK(iter);
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
-  int64 bigResult = 0;
+  int64_t bigResult = 0;
   if (!IteratorHasRoomFor(*iter, sizeof(bigResult)))
     return false;
 
   memcpy(&bigResult, *iter, sizeof(bigResult));
   DCHECK(bigResult <= std::numeric_limits<intptr_t>::max() && bigResult >= std::numeric_limits<intptr_t>::min());
   *result = static_cast<intptr_t>(bigResult);
 
   UpdateIter(iter, sizeof(bigResult));
@@ -357,31 +357,31 @@ bool Pickle::ReadString16(void** iter, s
   char16* chars = reinterpret_cast<char16*>(*iter);
   result->assign(chars, len);
 
   UpdateIter(iter, len * sizeof(char16));
   return true;
 }
 
 bool Pickle::ReadBytes(void** iter, const char** data, int length,
-                       uint32 alignment) const {
+                       uint32_t alignment) const {
   DCHECK(iter);
   DCHECK(data);
   DCHECK(alignment == 4 || alignment == 8);
   DCHECK(intptr_t(header_) % alignment == 0);
 
   if (!*iter)
     *iter = const_cast<char*>(payload());
 
-  uint32 paddingLen = intptr_t(*iter) % alignment;
+  uint32_t paddingLen = intptr_t(*iter) % alignment;
   if (paddingLen) {
 #ifdef DEBUG
     {
       const char* padding = static_cast<const char*>(*iter);
-      for (uint32 i = 0; i < paddingLen; i++) {
+      for (uint32_t i = 0; i < paddingLen; i++) {
         DCHECK(*(padding + i) == kBytePaddingMarker);
       }
     }
 #endif
     length += paddingLen;
   }
 
   if (!IteratorHasRoomFor(*iter, length))
@@ -402,32 +402,32 @@ bool Pickle::ReadData(void** iter, const
     *iter = const_cast<char*>(payload());
 
   if (!ReadLength(iter, length))
     return false;
 
   return ReadBytes(iter, data, *length);
 }
 
-char* Pickle::BeginWrite(uint32 length, uint32 alignment) {
+char* Pickle::BeginWrite(uint32_t length, uint32_t alignment) {
   DCHECK(alignment % 4 == 0) << "Must be at least 32-bit aligned!";
 
   // write at an alignment-aligned offset from the beginning of the header
-  uint32 offset = AlignInt(header_->payload_size, sizeof(uint32));
-  uint32 padding = (header_size_ + offset) %  alignment;
-  uint32 new_size = offset + padding + AlignInt(length, sizeof(uint32));
-  uint32 needed_size = header_size_ + new_size;
+  uint32_t offset = AlignInt(header_->payload_size, sizeof(uint32_t));
+  uint32_t padding = (header_size_ + offset) %  alignment;
+  uint32_t new_size = offset + padding + AlignInt(length, sizeof(uint32_t));
+  uint32_t needed_size = header_size_ + new_size;
 
   if (needed_size > capacity_ && !Resize(std::max(capacity_ * 2, needed_size)))
     return NULL;
 
   DCHECK(intptr_t(header_) % alignment == 0);
 
 #ifdef ARCH_CPU_64_BITS
-  DCHECK_LE(length, std::numeric_limits<uint32>::max());
+  DCHECK_LE(length, std::numeric_limits<uint32_t>::max());
 #endif
 
   char* buffer = payload() + offset;
 
   if (padding) {
     memset(buffer, kBytePaddingMarker, padding);
     buffer += padding;
   }
@@ -436,21 +436,21 @@ char* Pickle::BeginWrite(uint32 length, 
 
   header_->payload_size = new_size;
   return buffer;
 }
 
 void Pickle::EndWrite(char* dest, int length) {
   // Zero-pad to keep tools like purify from complaining about uninitialized
   // memory.
-  if (length % sizeof(uint32))
-    memset(dest + length, 0, sizeof(uint32) - (length % sizeof(uint32)));
+  if (length % sizeof(uint32_t))
+    memset(dest + length, 0, sizeof(uint32_t) - (length % sizeof(uint32_t)));
 }
 
-bool Pickle::WriteBytes(const void* data, int data_len, uint32 alignment) {
+bool Pickle::WriteBytes(const void* data, int data_len, uint32_t alignment) {
   DCHECK(capacity_ != kCapacityReadOnly) << "oops: pickle is readonly";
   DCHECK(alignment == 4 || alignment == 8);
   DCHECK(intptr_t(header_) % alignment == 0);
 
   char* dest = BeginWrite(data_len, alignment);
   if (!dest)
     return false;
 
@@ -489,17 +489,17 @@ bool Pickle::WriteData(const char* data,
 
 char* Pickle::BeginWriteData(int length) {
   DCHECK_EQ(variable_buffer_offset_, 0U) <<
     "There can only be one variable buffer in a Pickle";
 
   if (!WriteInt(length))
     return false;
 
-  char *data_ptr = BeginWrite(length, sizeof(uint32));
+  char *data_ptr = BeginWrite(length, sizeof(uint32_t));
   if (!data_ptr)
     return NULL;
 
   variable_buffer_offset_ =
       data_ptr - reinterpret_cast<char*>(header_) - sizeof(int);
 
   // EndWrite doesn't necessarily have to be called after the write operation,
   // so we call it here to pad out what the caller will eventually write.
@@ -519,34 +519,34 @@ void Pickle::TrimWriteData(int new_lengt
     return;
   }
 
   // Update the payload size and variable buffer size
   header_->payload_size -= (*cur_length - new_length);
   *cur_length = new_length;
 }
 
-bool Pickle::Resize(uint32 new_capacity) {
+bool Pickle::Resize(uint32_t new_capacity) {
   new_capacity = AlignInt(new_capacity, kPayloadUnit);
 
   void* p = realloc(header_, new_capacity);
   if (!p)
     return false;
 
   header_ = reinterpret_cast<Header*>(p);
   capacity_ = new_capacity;
   return true;
 }
 
 // static
-const char* Pickle::FindNext(uint32 header_size,
+const char* Pickle::FindNext(uint32_t header_size,
                              const char* start,
                              const char* end) {
-  DCHECK(header_size == AlignInt(header_size, sizeof(uint32)));
-  DCHECK(header_size <= static_cast<uint32>(kPayloadUnit));
+  DCHECK(header_size == AlignInt(header_size, sizeof(uint32_t)));
+  DCHECK(header_size <= static_cast<uint32_t>(kPayloadUnit));
 
   const Header* hdr = reinterpret_cast<const Header*>(start);
   const char* payload_base = start + header_size;
   const char* payload_end = payload_base + hdr->payload_size;
   if (payload_end < payload_base)
     return NULL;
 
   return (payload_end > end) ? NULL : payload_end;
--- a/ipc/chromium/src/base/pickle.h
+++ b/ipc/chromium/src/base/pickle.h
@@ -60,101 +60,101 @@ class Pickle {
   // Returns the data for this Pickle.
   const void* data() const { return header_; }
 
   // Methods for reading the payload of the Pickle.  To read from the start of
   // the Pickle, initialize *iter to NULL.  If successful, these methods return
   // true.  Otherwise, false is returned to indicate that the result could not
   // be extracted.
   bool ReadBool(void** iter, bool* result) const;
-  bool ReadInt16(void** iter, int16* result) const;
-  bool ReadUInt16(void** iter, uint16* result) const;
+  bool ReadInt16(void** iter, int16_t* result) const;
+  bool ReadUInt16(void** iter, uint16_t* result) const;
   bool ReadShort(void** iter, short* result) const;
   bool ReadInt(void** iter, int* result) const;
   bool ReadLong(void** iter, long* result) const;
   bool ReadULong(void** iter, unsigned long* result) const;
   bool ReadSize(void** iter, size_t* result) const;
-  bool ReadInt32(void** iter, int32* result) const;
-  bool ReadUInt32(void** iter, uint32* result) const;
-  bool ReadInt64(void** iter, int64* result) const;
-  bool ReadUInt64(void** iter, uint64* result) const;
+  bool ReadInt32(void** iter, int32_t* result) const;
+  bool ReadUInt32(void** iter, uint32_t* result) const;
+  bool ReadInt64(void** iter, int64_t* result) const;
+  bool ReadUInt64(void** iter, uint64_t* result) const;
   bool ReadDouble(void** iter, double* result) const;
   bool ReadIntPtr(void** iter, intptr_t* result) const;
   bool ReadUnsignedChar(void** iter, unsigned char* result) const;
   bool ReadString(void** iter, std::string* result) const;
   bool ReadWString(void** iter, std::wstring* result) const;
   bool ReadString16(void** iter, string16* result) const;
   bool ReadData(void** iter, const char** data, int* length) const;
   bool ReadBytes(void** iter, const char** data, int length,
-                 uint32 alignment = sizeof(uint32)) const;
+                 uint32_t alignment = sizeof(uint32_t)) const;
 
   // Safer version of ReadInt() checks for the result not being negative.
   // Use it for reading the object sizes.
   bool ReadLength(void** iter, int* result) const;
 
   // Methods for adding to the payload of the Pickle.  These values are
   // appended to the end of the Pickle's payload.  When reading values from a
   // Pickle, it is important to read them in the order in which they were added
   // to the Pickle.
   bool WriteBool(bool value) {
     return WriteInt(value ? 1 : 0);
   }
-  bool WriteInt16(int16 value) {
+  bool WriteInt16(int16_t value) {
     return WriteBytes(&value, sizeof(value));
   }
-  bool WriteUInt16(uint16 value) {
+  bool WriteUInt16(uint16_t value) {
     return WriteBytes(&value, sizeof(value));
   }
   bool WriteInt(int value) {
     return WriteBytes(&value, sizeof(value));
   }
   bool WriteLong(long value) {
     // Always written as a 64-bit value since the size for this type can
     // differ between architectures.
-    return WriteInt64(int64(value));
+    return WriteInt64(int64_t(value));
   }
   bool WriteULong(unsigned long value) {
     // Always written as a 64-bit value since the size for this type can
     // differ between architectures.
-    return WriteUInt64(uint64(value));
+    return WriteUInt64(uint64_t(value));
   }
   bool WriteSize(size_t value) {
     // Always written as a 64-bit value since the size for this type can
     // differ between architectures.
-    return WriteUInt64(uint64(value));
+    return WriteUInt64(uint64_t(value));
   }
-  bool WriteInt32(int32 value) {
+  bool WriteInt32(int32_t value) {
     return WriteBytes(&value, sizeof(value));
   }
-  bool WriteUInt32(uint32 value) {
+  bool WriteUInt32(uint32_t value) {
     return WriteBytes(&value, sizeof(value));
   }
-  bool WriteInt64(int64 value) {
+  bool WriteInt64(int64_t value) {
     return WriteBytes(&value, sizeof(value));
   }
-  bool WriteUInt64(uint64 value) {
+  bool WriteUInt64(uint64_t value) {
     return WriteBytes(&value, sizeof(value));
   }
   bool WriteDouble(double value) {
     return WriteBytes(&value, sizeof(value));
   }
   bool WriteIntPtr(intptr_t value) {
     // Always written as a 64-bit value since the size for this type can
     // differ between architectures.
-    return WriteInt64(int64(value));
+    return WriteInt64(int64_t(value));
   }
   bool WriteUnsignedChar(unsigned char value) {
     return WriteBytes(&value, sizeof(value));
   }
   bool WriteString(const std::string& value);
   bool WriteWString(const std::wstring& value);
   bool WriteString16(const string16& value);
   bool WriteData(const char* data, int length);
   bool WriteBytes(const void* data, int data_len,
-                  uint32 alignment = sizeof(uint32));
+                  uint32_t alignment = sizeof(uint32_t));
 
   // Same as WriteData, but allows the caller to write directly into the
   // Pickle. This saves a copy in cases where the data is not already
   // available in a buffer. The caller should take care to not write more
   // than the length it declares it will. Use ReadData to get the data.
   // Returns NULL on failure.
   //
   // The returned pointer will only be valid until the next write operation
@@ -173,17 +173,17 @@ class Pickle {
   void TrimWriteData(int length);
 
   void EndRead(void* iter) const {
     DCHECK(iter == end_of_payload());
   }
 
   // Payload follows after allocation of Header (header size is customizable).
   struct Header {
-    uint32 payload_size;  // Specifies the size of the payload.
+    uint32_t payload_size;  // Specifies the size of the payload.
   };
 
   // Returns the header, cast to a user-specified type T.  The type T must be a
   // subclass of Header and its size must correspond to the header_size passed
   // to the Pickle constructor.
   template <class T>
   T* headerT() {
     DCHECK(sizeof(T) == header_size_);
@@ -202,17 +202,17 @@ class Pickle {
     if ((len < 0) || (iter < header_) || iter > end_of_payload())
       return false;
     const char* end_of_region = reinterpret_cast<const char*>(iter) + len;
     // Watch out for overflow in pointer calculation, which wraps.
     return (iter <= end_of_region) && (end_of_region <= end_of_payload());
   }
 
  protected:
-  uint32 payload_size() const { return header_->payload_size; }
+  uint32_t payload_size() const { return header_->payload_size; }
 
   char* payload() {
     return reinterpret_cast<char*>(header_) + header_size_;
   }
   const char* payload() const {
     return reinterpret_cast<const char*>(header_) + header_size_;
   }
 
@@ -220,61 +220,61 @@ class Pickle {
   // header + payload.
   char* end_of_payload() {
     return payload() + payload_size();
   }
   const char* end_of_payload() const {
     return payload() + payload_size();
   }
 
-  uint32 capacity() const {
+  uint32_t capacity() const {
     return capacity_;
   }
 
   // Resizes the buffer for use when writing the specified amount of data. The
   // location that the data should be written at is returned, or NULL if there
   // was an error. Call EndWrite with the returned offset and the given length
   // to pad out for the next write.
-  char* BeginWrite(uint32 length, uint32 alignment);
+  char* BeginWrite(uint32_t length, uint32_t alignment);
 
   // Completes the write operation by padding the data with NULL bytes until it
   // is padded. Should be paired with BeginWrite, but it does not necessarily
   // have to be called after the data is written.
   void EndWrite(char* dest, int length);
 
   // Resize the capacity, note that the input value should include the size of
   // the header: new_capacity = sizeof(Header) + desired_payload_capacity.
   // A realloc() failure will cause a Resize failure... and caller should check
   // the return result for true (i.e., successful resizing).
-  bool Resize(uint32 new_capacity);
+  bool Resize(uint32_t new_capacity);
 
   // Aligns 'i' by rounding it up to the next multiple of 'alignment'
-  static uint32 AlignInt(uint32 i, int alignment) {
+  static uint32_t AlignInt(uint32_t i, int alignment) {
     return i + (alignment - (i % alignment)) % alignment;
   }
 
   // Moves the iterator by the given number of bytes, making sure it is aligned.
   // Pointer (iterator) is NOT aligned, but the change in the pointer
-  // is guaranteed to be a multiple of sizeof(uint32).
+  // is guaranteed to be a multiple of sizeof(uint32_t).
   static void UpdateIter(void** iter, int bytes) {
-    *iter = static_cast<char*>(*iter) + AlignInt(bytes, sizeof(uint32));
+    *iter = static_cast<char*>(*iter) + AlignInt(bytes, sizeof(uint32_t));
   }
 
   // Find the end of the pickled data that starts at range_start.  Returns NULL
   // if the entire Pickle is not found in the given data range.
-  static const char* FindNext(uint32 header_size,
+  static const char* FindNext(uint32_t header_size,
                               const char* range_start,
                               const char* range_end);
 
   // The allocation granularity of the payload.
   static const int kPayloadUnit;
 
  private:
   Header* header_;
-  uint32 header_size_;
-  uint32 capacity_;
-  uint32 variable_buffer_offset_;
+  uint32_t header_size_;
+  uint32_t capacity_;
+  uint32_t variable_buffer_offset_;
   FRIEND_TEST(PickleTest, Resize);
   FRIEND_TEST(PickleTest, FindNext);
   FRIEND_TEST(PickleTest, IteratorHasRoom);
 };
 
 #endif  // BASE_PICKLE_H__
--- a/ipc/chromium/src/base/pickle_unittest.cc
+++ b/ipc/chromium/src/base/pickle_unittest.cc
@@ -156,28 +156,28 @@ TEST(PickleTest, Resize) {
   size_t unit = Pickle::kPayloadUnit;
   scoped_array<char> data(new char[unit]);
   char* data_ptr = data.get();
   for (size_t i = 0; i < unit; i++)
     data_ptr[i] = 'G';
 
   // construct a message that will be exactly the size of one payload unit,
   // note that any data will have a 4-byte header indicating the size
-  const size_t payload_size_after_header = unit - sizeof(uint32);
+  const size_t payload_size_after_header = unit - sizeof(uint32_t);
   Pickle pickle;
   pickle.WriteData(data_ptr,
-      static_cast<int>(payload_size_after_header - sizeof(uint32)));
+      static_cast<int>(payload_size_after_header - sizeof(uint32_t)));
   size_t cur_payload = payload_size_after_header;
 
   // note: we assume 'unit' is a power of 2
   EXPECT_EQ(unit, pickle.capacity());
   EXPECT_EQ(pickle.payload_size(), payload_size_after_header);
 
   // fill out a full page (noting data header)
-  pickle.WriteData(data_ptr, static_cast<int>(unit - sizeof(uint32)));
+  pickle.WriteData(data_ptr, static_cast<int>(unit - sizeof(uint32_t)));
   cur_payload += unit;
   EXPECT_EQ(unit * 2, pickle.capacity());
   EXPECT_EQ(cur_payload, pickle.payload_size());
 
   // one more byte should double the capacity
   pickle.WriteData(data_ptr, 1);
   cur_payload += 5;
   EXPECT_EQ(unit * 4, pickle.capacity());
@@ -188,29 +188,29 @@ namespace {
 
 struct CustomHeader : Pickle::Header {
   int blah;
 };
 
 }  // namespace
 
 TEST(PickleTest, HeaderPadding) {
-  const uint32 kMagic = 0x12345678;
+  const uint32_t kMagic = 0x12345678;
 
   Pickle pickle(sizeof(CustomHeader));
   pickle.WriteInt(kMagic);
 
   // this should not overwrite the 'int' payload
   pickle.headerT<CustomHeader>()->blah = 10;
 
   void* iter = NULL;
   int result;
   ASSERT_TRUE(pickle.ReadInt(&iter, &result));
 
-  EXPECT_EQ(static_cast<uint32>(result), kMagic);
+  EXPECT_EQ(static_cast<uint32_t>(result), kMagic);
 }
 
 TEST(PickleTest, EqualsOperator) {
   Pickle source;
   source.WriteInt(1);
 
   Pickle copy_refs_source_buffer(static_cast<const char*>(source.data()),
                                  source.size());
--- a/ipc/chromium/src/base/process_util.h
+++ b/ipc/chromium/src/base/process_util.h
@@ -417,18 +417,18 @@ class ProcessMetrics {
  private:
   explicit ProcessMetrics(ProcessHandle process);
 
   ProcessHandle process_;
 
   int processor_count_;
 
   // Used to store the previous times so we can compute the CPU usage.
-  int64 last_time_;
-  int64 last_system_time_;
+  int64_t last_time_;
+  int64_t last_system_time_;
 
   DISALLOW_EVIL_CONSTRUCTORS(ProcessMetrics);
 };
 
 // Enables low fragmentation heap (LFH) for every heaps of this process. This
 // won't have any effect on heaps created after this function call. It will not
 // modify data allocated in the heaps before calling this function. So it is
 // better to call this function early in initialization and again before
--- a/ipc/chromium/src/base/process_util_posix.cc
+++ b/ipc/chromium/src/base/process_util_posix.cc
@@ -328,27 +328,27 @@ int WaitpidWithTimeout(ProcessHandle han
   // usleep() is speced to exit if a signal is received for which a handler
   // has been installed.  This means that when a SIGCHLD is sent, it will exit
   // depending on behavior external to this function.
   //
   // This function is used primarily for unit tests, if we want to use it in
   // the application itself it would probably be best to examine other routes.
   int status = -1;
   pid_t ret_pid = HANDLE_EINTR(waitpid(handle, &status, WNOHANG));
-  static const int64 kQuarterSecondInMicroseconds = kMicrosecondsPerSecond/4;
+  static const int64_t kQuarterSecondInMicroseconds = kMicrosecondsPerSecond/4;
 
   // If the process hasn't exited yet, then sleep and try again.
   Time wakeup_time = Time::Now() + TimeDelta::FromMilliseconds(
       wait_milliseconds);
   while (ret_pid == 0) {
     Time now = Time::Now();
     if (now > wakeup_time)
       break;
     // Guaranteed to be non-negative!
-    int64 sleep_time_usecs = (wakeup_time - now).InMicroseconds();
+    int64_t sleep_time_usecs = (wakeup_time - now).InMicroseconds();
     // Don't sleep for more than 0.25 secs at a time.
     if (sleep_time_usecs > kQuarterSecondInMicroseconds) {
       sleep_time_usecs = kQuarterSecondInMicroseconds;
     }
 
     // usleep() will return 0 and set errno to EINTR on receipt of a signal
     // such as SIGCHLD.
     usleep(sleep_time_usecs);
@@ -388,47 +388,47 @@ bool CrashAwareSleep(ProcessHandle handl
     // If waitpid returned with an error, then the process doesn't exist
     // (which most probably means it didn't exist before our call).
     return waitpid_success;
   }
 }
 
 namespace {
 
-int64 TimeValToMicroseconds(const struct timeval& tv) {
+int64_t TimeValToMicroseconds(const struct timeval& tv) {
   return tv.tv_sec * kMicrosecondsPerSecond + tv.tv_usec;
 }
 
 }
 
 int ProcessMetrics::GetCPUUsage() {
   struct timeval now;
   struct rusage usage;
 
   int retval = gettimeofday(&now, NULL);
   if (retval)
     return 0;
   retval = getrusage(RUSAGE_SELF, &usage);
   if (retval)
     return 0;
 
-  int64 system_time = (TimeValToMicroseconds(usage.ru_stime) +
+  int64_t system_time = (TimeValToMicroseconds(usage.ru_stime) +
                        TimeValToMicroseconds(usage.ru_utime)) /
                         processor_count_;
-  int64 time = TimeValToMicroseconds(now);
+  int64_t time = TimeValToMicroseconds(now);
 
   if ((last_system_time_ == 0) || (last_time_ == 0)) {
     // First call, just set the last values.
     last_system_time_ = system_time;
     last_time_ = time;
     return 0;
   }
 
-  int64 system_time_delta = system_time - last_system_time_;
-  int64 time_delta = time - last_time_;
+  int64_t system_time_delta = system_time - last_system_time_;
+  int64_t time_delta = time - last_time_;
   DCHECK(time_delta != 0);
   if (time_delta == 0)
     return 0;
 
   // We add time_delta / 2 so the result is rounded.
   int cpu = static_cast<int>((system_time_delta * 100 + time_delta / 2) /
                              time_delta);
 
--- a/ipc/chromium/src/base/process_util_unittest.cc
+++ b/ipc/chromium/src/base/process_util_unittest.cc
@@ -168,19 +168,19 @@ TEST_F(ProcessUtilTest, GetAppOutput) {
 // Returns the maximum number of files that a process can have open.
 // Returns 0 on error.
 int GetMaxFilesOpenInProcess() {
   struct rlimit rlim;
   if (getrlimit(RLIMIT_NOFILE, &rlim) != 0) {
     return 0;
   }
 
-  // rlim_t is a uint64 - clip to maxint. We do this since FD #s are ints
+  // rlim_t is a uint64_t - clip to maxint. We do this since FD #s are ints
   // which are all 32 bits on the supported platforms.
-  rlim_t max_int = static_cast<rlim_t>(std::numeric_limits<int32>::max());
+  rlim_t max_int = static_cast<rlim_t>(std::numeric_limits<int32_t>::max());
   if (rlim.rlim_cur > max_int) {
     return max_int;
   }
 
   return rlim.rlim_cur;
 }
 
 const int kChildPipe = 20;  // FD # for write end of pipe in child process.
--- a/ipc/chromium/src/base/process_util_win.cc
+++ b/ipc/chromium/src/base/process_util_win.cc
@@ -612,17 +612,17 @@ bool ProcessMetrics::GetWorkingSetKBytes
 
   ws_usage->priv = ws_private * PAGESIZE_KB;
   ws_usage->shareable = ws_shareable * PAGESIZE_KB;
   ws_usage->shared = ws_shared * PAGESIZE_KB;
   free(buffer);
   return true;
 }
 
-static uint64 FileTimeToUTC(const FILETIME& ftime) {
+static uint64_t FileTimeToUTC(const FILETIME& ftime) {
   LARGE_INTEGER li;
   li.LowPart = ftime.dwLowDateTime;
   li.HighPart = ftime.dwHighDateTime;
   return li.QuadPart;
 }
 
 int ProcessMetrics::GetCPUUsage() {
   FILETIME now;
@@ -635,29 +635,29 @@ int ProcessMetrics::GetCPUUsage() {
 
   if (!GetProcessTimes(process_, &creation_time, &exit_time,
                        &kernel_time, &user_time)) {
     // We don't assert here because in some cases (such as in the Task Manager)
     // we may call this function on a process that has just exited but we have
     // not yet received the notification.
     return 0;
   }
-  int64 system_time = (FileTimeToUTC(kernel_time) + FileTimeToUTC(user_time)) /
+  int64_t system_time = (FileTimeToUTC(kernel_time) + FileTimeToUTC(user_time)) /
                         processor_count_;
-  int64 time = FileTimeToUTC(now);
+  int64_t time = FileTimeToUTC(now);
 
   if ((last_system_time_ == 0) || (last_time_ == 0)) {
     // First call, just set the last values.
     last_system_time_ = system_time;
     last_time_ = time;
     return 0;
   }
 
-  int64 system_time_delta = system_time - last_system_time_;
-  int64 time_delta = time - last_time_;
+  int64_t system_time_delta = system_time - last_system_time_;
+  int64_t time_delta = time - last_time_;
   DCHECK(time_delta != 0);
   if (time_delta == 0)
     return 0;
 
   // We add time_delta / 2 so the result is rounded.
   int cpu = static_cast<int>((system_time_delta * 100 + time_delta / 2) /
                              time_delta);
 
--- a/ipc/chromium/src/base/rand_util.cc
+++ b/ipc/chromium/src/base/rand_util.cc
@@ -11,30 +11,30 @@
 #include "base/basictypes.h"
 #include "base/logging.h"
 
 namespace base {
 
 int RandInt(int min, int max) {
   DCHECK(min <= max);
 
-  uint64 range = static_cast<int64>(max) - min + 1;
-  uint64 number = base::RandUint64();
+  uint64_t range = static_cast<int64_t>(max) - min + 1;
+  uint64_t number = base::RandUint64();
   int result = min + static_cast<int>(number % range);
   DCHECK(result >= min && result <= max);
   return result;
 }
 
 double RandDouble() {
   // We try to get maximum precision by masking out as many bits as will fit
   // in the target type's mantissa, and raising it to an appropriate power to
   // produce output in the range [0, 1).  For IEEE 754 doubles, the mantissa
   // is expected to accommodate 53 bits.
 
   COMPILE_ASSERT(std::numeric_limits<double>::radix == 2, otherwise_use_scalbn);
   static const int kBits = std::numeric_limits<double>::digits;
-  uint64 random_bits = base::RandUint64() & ((GG_UINT64_C(1) << kBits) - 1);
+  uint64_t random_bits = base::RandUint64() & ((GG_UINT64_C(1) << kBits) - 1);
   double result = ldexp(static_cast<double>(random_bits), -1 * kBits);
   DCHECK(result >= 0.0 && result < 1.0);
   return result;
 }
 
 }  // namespace base
--- a/ipc/chromium/src/base/rand_util.h
+++ b/ipc/chromium/src/base/rand_util.h
@@ -5,17 +5,17 @@
 #ifndef BASE_RAND_UTIL_H_
 #define BASE_RAND_UTIL_H_
 
 #include "base/basictypes.h"
 
 namespace base {
 
 // Returns a random number in range [0, kuint64max]. Thread-safe.
-uint64 RandUint64();
+uint64_t RandUint64();
 
 // Returns a random number between min and max (inclusive). Thread-safe.
 int RandInt(int min, int max);
 
 // Returns a random double in range [0, 1). Thread-safe.
 double RandDouble();
 
 }  // namespace base
--- a/ipc/chromium/src/base/rand_util_posix.cc
+++ b/ipc/chromium/src/base/rand_util_posix.cc
@@ -7,18 +7,18 @@
 #include <fcntl.h>
 #include <unistd.h>
 
 #include "base/file_util.h"
 #include "base/logging.h"
 
 namespace base {
 
-uint64 RandUint64() {
-  uint64 number;
+uint64_t RandUint64() {
+  uint64_t number;
 
   int urandom_fd = open("/dev/urandom", O_RDONLY);
   CHECK(urandom_fd >= 0);
   bool success = file_util::ReadFromFD(urandom_fd,
                                        reinterpret_cast<char*>(&number),
                                        sizeof(number));
   CHECK(success);
   close(urandom_fd);
--- a/ipc/chromium/src/base/rand_util_win.cc
+++ b/ipc/chromium/src/base/rand_util_win.cc
@@ -6,25 +6,25 @@
 
 #include <stdlib.h>
 
 #include "base/basictypes.h"
 #include "base/logging.h"
 
 namespace {
 
-uint32 RandUint32() {
-  uint32 number;
+uint32_t RandUint32() {
+  uint32_t number;
   CHECK(rand_s(&number) == 0);
   return number;
 }
 
 }  // namespace
 
 namespace base {
 
-uint64 RandUint64() {
-  uint32 first_half = RandUint32();
-  uint32 second_half = RandUint32();
-  return (static_cast<uint64>(first_half) << 32) + second_half;
+uint64_t RandUint64() {
+  uint32_t first_half = RandUint32();
+  uint32_t second_half = RandUint32();
+  return (static_cast<uint64_t>(first_half) << 32) + second_half;
 }
 
 }  // namespace base
--- a/ipc/chromium/src/base/scoped_bstr_win.cc
+++ b/ipc/chromium/src/base/scoped_bstr_win.cc
@@ -46,21 +46,21 @@ BSTR ScopedBstr::Allocate(const wchar_t*
   return bstr_;
 }
 
 BSTR ScopedBstr::AllocateBytes(int bytes) {
   Reset(SysAllocStringByteLen(NULL, bytes));
   return bstr_;
 }
 
-void ScopedBstr::SetByteLen(uint32 bytes) {
+void ScopedBstr::SetByteLen(uint32_t bytes) {
   DCHECK(bstr_ != NULL) << "attempting to modify a NULL bstr";
-  uint32* data = reinterpret_cast<uint32*>(bstr_);
+  uint32_t* data = reinterpret_cast<uint32_t*>(bstr_);
   data[-1] = bytes;
 }
 
-uint32 ScopedBstr::Length() const {
+uint32_t ScopedBstr::Length() const {
   return SysStringLen(bstr_);
 }
 
-uint32 ScopedBstr::ByteLength() const {
+uint32_t ScopedBstr::ByteLength() const {
   return SysStringByteLen(bstr_);
 }
--- a/ipc/chromium/src/base/scoped_bstr_win.h
+++ b/ipc/chromium/src/base/scoped_bstr_win.h
@@ -47,32 +47,32 @@ class ScopedBstr {
   // SysAllocStringLen or SysAllocStringByteLen (call |AllocateBytes|) and
   // then not all the bytes are being used.
   // Note that if you want to set the length to a specific number of characters,
   // you need to multiply by sizeof(wchar_t).  Oddly, there's no public API to
   // set the length, so we do this ourselves by hand.
   //
   // NOTE: The actual allocated size of the BSTR MUST be >= bytes.
   //  That responsibility is with the caller.
-  void SetByteLen(uint32 bytes);
+  void SetByteLen(uint32_t bytes);
 
   // Swap values of two ScopedBstr's.
   void Swap(ScopedBstr& bstr2);
 
   // Retrieves the pointer address.
   // Used to receive BSTRs as out arguments (and take ownership).
   // The function DCHECKs on the current value being NULL.
   // Usage: GetBstr(bstr.Receive());
   BSTR* Receive();
 
   // Returns number of chars in the BSTR.
-  uint32 Length() const;
+  uint32_t Length() const;
 
   // Returns the number of bytes allocated for the BSTR.
-  uint32 ByteLength() const;
+  uint32_t ByteLength() const;
 
   operator BSTR() const {
     return bstr_;
   }
 
  protected:
   BSTR bstr_;
 
@@ -82,27 +82,27 @@ class ScopedBstr {
   bool operator==(const ScopedBstr& bstr2) const;
   bool operator!=(const ScopedBstr& bstr2) const;
   DISALLOW_COPY_AND_ASSIGN(ScopedBstr);
 };
 
 // Template class to generate a BSTR from a static wide string
 // without touching the heap.  Use this class via the StackBstrVar and
 // StackBstr macros.
-template <uint32 string_bytes>
+template <uint32_t string_bytes>
 class StackBstrT {
  public:
   // Try to stay as const as we can in an attempt to avoid someone
   // using the class incorrectly (e.g. by supplying a variable instead
   // of a verbatim string.  We also have an assert in the constructor
   // as an extra runtime check since the const-ness only catches one case.
   explicit StackBstrT(const wchar_t* const str) {
-    // The BSTR API uses UINT, but we prefer uint32.
+    // The BSTR API uses UINT, but we prefer uint32_t.
     // Make sure we'll know about it if these types don't match.
-    COMPILE_ASSERT(sizeof(uint32) == sizeof(UINT), UintToUint32);
+    COMPILE_ASSERT(sizeof(uint32_t) == sizeof(UINT), UintToUint32);
     COMPILE_ASSERT(sizeof(wchar_t) == sizeof(OLECHAR), WcharToOlechar);
 
     // You shouldn't pass string pointers to this constructor since
     // there's no way for the compiler to calculate the length of the
     // string (string_bytes will be equal to pointer size in those cases).
     DCHECK(lstrlenW(str) == (string_bytes / sizeof(bstr_.str_[0])) - 1) <<
         "not expecting a string pointer";
     memcpy(bstr_.str_, str, string_bytes);
@@ -110,17 +110,17 @@ class StackBstrT {
   }
 
   operator BSTR() {
     return bstr_.str_;
   }
 
  protected:
   struct BstrInternal {
-    uint32 len_;
+    uint32_t len_;
     wchar_t str_[string_bytes / sizeof(wchar_t)];
   } bstr_;
 };
 
 // Use this macro to generate an inline BSTR from a wide string.
 // This is about 6 times faster than using the SysAllocXxx functions to
 // allocate a BSTR and helps with keeping heap fragmentation down.
 // Example:
--- a/ipc/chromium/src/base/scoped_bstr_win_unittest.cc
+++ b/ipc/chromium/src/base/scoped_bstr_win_unittest.cc
@@ -4,18 +4,18 @@
 
 #include "base/scoped_bstr_win.h"
 #include "testing/gtest/include/gtest/gtest.h"
 
 namespace {
 
 static const wchar_t kTestString1[] = L"123";
 static const wchar_t kTestString2[] = L"456789";
-uint32 test1_len = arraysize(kTestString1) - 1;
-uint32 test2_len = arraysize(kTestString2) - 1;
+uint32_t test1_len = arraysize(kTestString1) - 1;
+uint32_t test2_len = arraysize(kTestString2) - 1;
 
 void DumbBstrTests() {
   ScopedBstr b;
   EXPECT_TRUE(b == NULL);
   EXPECT_TRUE(b.Length() == 0);
   EXPECT_TRUE(b.ByteLength() == 0);
   b.Reset(NULL);
   EXPECT_TRUE(b == NULL);
@@ -75,19 +75,19 @@ TEST(ScopedBstrTest, ScopedBstr) {
 
 TEST(StackBstrTest, StackBstr) {
   ScopedBstr system_bstr(kSourceStr);
   StackBstrVar(kSourceStr, stack_bstr);
   EXPECT_EQ(VarBstrCmp(system_bstr, stack_bstr, LOCALE_USER_DEFAULT, 0),
             VARCMP_EQ);
 
   StackBstrVar(kSourceStrEmpty, empty);
-  uint32 l1 = SysStringLen(stack_bstr);
-  uint32 l2 = SysStringLen(StackBstr(kSourceStr));
-  uint32 l3 = SysStringLen(system_bstr);
+  uint32_t l1 = SysStringLen(stack_bstr);
+  uint32_t l2 = SysStringLen(StackBstr(kSourceStr));
+  uint32_t l3 = SysStringLen(system_bstr);
   EXPECT_TRUE(l1 == l2);
   EXPECT_TRUE(l2 == l3);
   EXPECT_TRUE(SysStringLen(empty) == 0);
 
   const wchar_t one_more_test[] = L"this is my const string";
   EXPECT_EQ(SysStringLen(StackBstr(one_more_test)),
             lstrlenW(one_more_test));
 }
--- a/ipc/chromium/src/base/scoped_variant_win.cc
+++ b/ipc/chromium/src/base/scoped_variant_win.cc
@@ -98,59 +98,59 @@ int ScopedVariant::Compare(const VARIANT
 }
 
 void ScopedVariant::Set(const wchar_t* str) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_BSTR;
   var_.bstrVal = ::SysAllocString(str);
 }
 
-void ScopedVariant::Set(int8 i8) {
+void ScopedVariant::Set(int8_t i8) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_I1;
   var_.cVal = i8;
 }
 
-void ScopedVariant::Set(uint8 ui8) {
+void ScopedVariant::Set(uint8_t ui8) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_UI1;
   var_.bVal = ui8;
 }
 
-void ScopedVariant::Set(int16 i16) {
+void ScopedVariant::Set(int16_t i16) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_I2;
   var_.iVal = i16;
 }
 
-void ScopedVariant::Set(uint16 ui16) {
+void ScopedVariant::Set(uint16_t ui16) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_UI2;
   var_.uiVal = ui16;
 }
 
-void ScopedVariant::Set(int32 i32) {
+void ScopedVariant::Set(int32_t i32) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_I4;
   var_.lVal = i32;
 }
 
-void ScopedVariant::Set(uint32 ui32) {
+void ScopedVariant::Set(uint32_t ui32) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_UI4;
   var_.ulVal = ui32;
 }
 
-void ScopedVariant::Set(int64 i64) {
+void ScopedVariant::Set(int64_t i64) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_I8;
   var_.llVal = i64;
 }
 
-void ScopedVariant::Set(uint64 ui64) {
+void ScopedVariant::Set(uint64_t ui64) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_UI8;
   var_.ullVal = ui64;
 }
 
 void ScopedVariant::Set(float r32) {
   DCHECK(!IsLeakableVarType(var_.vt)) << "leaking variant: " << var_.vt;
   var_.vt = VT_R4;
--- a/ipc/chromium/src/base/scoped_variant_win.h
+++ b/ipc/chromium/src/base/scoped_variant_win.h
@@ -75,24 +75,24 @@ class ScopedVariant {
   // Used to receive a VARIANT as an out argument (and take ownership).
   // The function DCHECKs on the current value being empty/null.
   // Usage: GetVariant(var.receive());
   VARIANT* Receive();
 
   void Set(const wchar_t* str);
 
   // Setters for simple types.
-  void Set(int8 i8);
-  void Set(uint8 ui8);
-  void Set(int16 i16);
-  void Set(uint16 ui16);
-  void Set(int32 i32);
-  void Set(uint32 ui32);
-  void Set(int64 i64);
-  void Set(uint64 ui64);
+  void Set(int8_t i8);
+  void Set(uint8_t ui8);
+  void Set(int16_t i16);
+  void Set(uint16_t ui16);
+  void Set(int32_t i32);
+  void Set(uint32_t ui32);
+  void Set(int64_t i64);
+  void Set(uint64_t ui64);
   void Set(float r32);
   void Set(double r64);
   void Set(bool b);
 
   // Creates a copy of |var| and assigns as this instance's value.
   // Note that this is different from the Reset() method that's used to
   // free the current value and assume ownership.
   void Set(const VARIANT& var);
--- a/ipc/chromium/src/base/scoped_variant_win_unittest.cc
+++ b/ipc/chromium/src/base/scoped_variant_win_unittest.cc
@@ -118,45 +118,45 @@ TEST(ScopedVariantTest, ScopedVariant) {
   EXPECT_EQ(VT_DATE, var.type());
   EXPECT_EQ(date, V_DATE(&var));
 
   // Simple setter tests.  These do not require resetting the variant
   // after each test since the variant type is not "leakable" (i.e. doesn't
   // need to be freed explicitly).
 
   // We need static cast here since char defaults to int (!?).
-  var.Set(static_cast<int8>('v'));
+  var.Set(static_cast<int8_t>('v'));
   EXPECT_EQ(VT_I1, var.type());
   EXPECT_EQ('v', V_I1(&var));
 
   var.Set(static_cast<short>(123));
   EXPECT_EQ(VT_I2, var.type());
   EXPECT_EQ(123, V_I2(&var));
 
-  var.Set(static_cast<int32>(123));
+  var.Set(static_cast<int32_t>(123));
   EXPECT_EQ(VT_I4, var.type());
   EXPECT_EQ(123, V_I4(&var));
 
-  var.Set(static_cast<int64>(123));
+  var.Set(static_cast<int64_t>(123));
   EXPECT_EQ(VT_I8, var.type());
   EXPECT_EQ(123, V_I8(&var));
 
-  var.Set(static_cast<uint8>(123));
+  var.Set(static_cast<uint8_t>(123));
   EXPECT_EQ(VT_UI1, var.type());
   EXPECT_EQ(123, V_UI1(&var));
 
   var.Set(static_cast<unsigned short>(123));
   EXPECT_EQ(VT_UI2, var.type());
   EXPECT_EQ(123, V_UI2(&var));
 
-  var.Set(static_cast<uint32>(123));
+  var.Set(static_cast<uint32_t>(123));
   EXPECT_EQ(VT_UI4, var.type());
   EXPECT_EQ(123, V_UI4(&var));
 
-  var.Set(static_cast<uint64>(123));
+  var.Set(static_cast<uint64_t>(123));
   EXPECT_EQ(VT_UI8, var.type());
   EXPECT_EQ(123, V_UI8(&var));
 
   var.Set(123.123f);
   EXPECT_EQ(VT_R4, var.type());
   EXPECT_EQ(123.123f, V_R4(&var));
 
   var.Set(static_cast<double>(123.123));
--- a/ipc/chromium/src/base/shared_memory_unittest.cc
+++ b/ipc/chromium/src/base/shared_memory_unittest.cc
@@ -17,17 +17,17 @@ namespace base {
 
 namespace {
 
 // Each thread will open the shared memory.  Each thread will take a different 4
 // byte int pointer, and keep changing it, with some small pauses in between.
 // Verify that each thread's value in the shared memory is always correct.
 class MultipleThreadMain : public PlatformThread::Delegate {
  public:
-  explicit MultipleThreadMain(int16 id) : id_(id) {}
+  explicit MultipleThreadMain(int16_t id) : id_(id) {}
   ~MultipleThreadMain() {}
 
   static void CleanUp() {
     SharedMemory memory;
     memory.Delete(s_test_name_);
   }
 
   // PlatformThread::Delegate interface.
@@ -47,17 +47,17 @@ class MultipleThreadMain : public Platfo
       PlatformThread::Sleep(1);  // Short wait.
       EXPECT_EQ(*ptr, idx);
     }
 
     memory.Close();
   }
 
  private:
-  int16 id_;
+  int16_t id_;
 
   static const wchar_t* const s_test_name_;
 
   DISALLOW_COPY_AND_ASSIGN(MultipleThreadMain);
 };
 
 const wchar_t* const MultipleThreadMain::s_test_name_ =
     L"SharedMemoryOpenThreadTest";
@@ -178,17 +178,17 @@ TEST(SharedMemoryTest, MultipleThreads) 
     int numthreads = threadcounts[i];
     scoped_array<PlatformThreadHandle> thread_handles;
     scoped_array<MultipleThreadMain*> thread_delegates;
 
     thread_handles.reset(new PlatformThreadHandle[numthreads]);
     thread_delegates.reset(new MultipleThreadMain*[numthreads]);
 
     // Spawn the threads.
-    for (int16 index = 0; index < numthreads; index++) {
+    for (int16_t index = 0; index < numthreads; index++) {
       PlatformThreadHandle pth;
       thread_delegates[index] = new MultipleThreadMain(index);
       EXPECT_TRUE(PlatformThread::Create(0, thread_delegates[index], &pth));
       thread_handles[index] = pth;
     }
 
     // Wait for the threads to finish.
     for (int index = 0; index < numthreads; index++) {
--- a/ipc/chromium/src/base/stats_counters.h
+++ b/ipc/chromium/src/base/stats_counters.h
@@ -152,17 +152,17 @@ class StatsCounter {
     // counter_id_ was zero, which means the table is full.
     return NULL;
   }
 
   std::string name_;
   // The counter id in the table.  We initialize to -1 (an invalid value)
   // and then cache it once it has been looked up.  The counter_id is
   // valid across all threads and processes.
-  int32 counter_id_;
+  int32_t counter_id_;
 };
 
 
 // A StatsCounterTimer is a StatsCounter which keeps a timer during
 // the scope of the StatsCounterTimer.  On destruction, it will record
 // its time measurement.
 class StatsCounterTimer : protected StatsCounter {
  public:
--- a/ipc/chromium/src/base/stats_table_unittest.cc
+++ b/ipc/chromium/src/base/stats_table_unittest.cc
@@ -201,17 +201,17 @@ TEST_F(StatsTableTest, MultipleProcesses
   EXPECT_EQ(0, table.CountThreadsRegistered());
 
   // Spin up a set of processes to go bang on the various counters.
   // After we join the processes, we'll make sure the counters
   // contain the values we expected.
   ProcessHandle procs[kMaxProcs];
 
   // Spawn the processes.
-  for (int16 index = 0; index < kMaxProcs; index++) {
+  for (int16_t index = 0; index < kMaxProcs; index++) {
     procs[index] = this->SpawnChild(L"StatsTableMultipleProcessMain");
     EXPECT_NE(static_cast<ProcessHandle>(NULL), procs[index]);
   }
 
   // Wait for the processes to finish.
   for (int index = 0; index < kMaxProcs; index++) {
     EXPECT_TRUE(WaitForSingleProcess(procs[index], 60 * 1000));
     base::CloseProcessHandle(procs[index]);
--- a/ipc/chromium/src/base/string16.h
+++ b/ipc/chromium/src/base/string16.h
@@ -33,17 +33,17 @@
 
 #if defined(WCHAR_T_IS_UTF16)
 
 typedef wchar_t char16;
 typedef std::wstring string16;
 
 #elif defined(WCHAR_T_IS_UTF32)
 
-typedef uint16 char16;
+typedef uint16_t char16;
 
 namespace base {
 
 // char16 versions of the functions required by string16_char_traits; these
 // are based on the wide character functions of similar names ("w" or "wcs"
 // instead of "c16").
 int c16memcmp(const char16* s1, const char16* s2, size_t n);
 size_t c16len(const char16* s);
--- a/ipc/chromium/src/base/string_util.cc
+++ b/ipc/chromium/src/base/string_util.cc
@@ -52,17 +52,17 @@ template<>
 struct ToUnsigned<signed char> {
   typedef unsigned char Unsigned;
 };
 template<>
 struct ToUnsigned<wchar_t> {
 #if defined(WCHAR_T_IS_UTF16)
   typedef unsigned short Unsigned;
 #elif defined(WCHAR_T_IS_UTF32)
-  typedef uint32 Unsigned;
+  typedef uint32_t Unsigned;
 #endif
 };
 template<>
 struct ToUnsigned<short> {
   typedef unsigned short Unsigned;
 };
 
 // Used by ReplaceStringPlaceholders to track the position in the string of
@@ -159,17 +159,17 @@ class String16ToLongTraits {
   static inline bool valid_func(const string_type& str) {
     return !str.empty() && !iswspace(str[0]);
   }
 };
 
 class StringToInt64Traits {
  public:
   typedef std::string string_type;
-  typedef int64 value_type;
+  typedef int64_t value_type;
   static const int kBase = 10;
   static inline value_type convert_func(const string_type::value_type* str,
                                         string_type::value_type** endptr) {
 #ifdef OS_WIN
     return _strtoi64(str, endptr, kBase);
 #else  // assume OS_POSIX
     return strtoll(str, endptr, kBase);
 #endif
@@ -177,17 +177,17 @@ class StringToInt64Traits {
   static inline bool valid_func(const string_type& str) {
     return !str.empty() && !isspace(str[0]);
   }
 };
 
 class String16ToInt64Traits {
  public:
   typedef string16 string_type;
-  typedef int64 value_type;
+  typedef int64_t value_type;
   static const int kBase = 10;
   static inline value_type convert_func(const string_type::value_type* str,
                                         string_type::value_type** endptr) {
 #ifdef OS_WIN
     return _wcstoi64(str, endptr, kBase);
 #else  // assume OS_POSIX
     std::string ascii_string = UTF16ToASCII(string16(str));
     char* ascii_end = NULL;
@@ -716,21 +716,21 @@ bool StartsWith(const std::wstring& str,
   else {
     if (search.size() > str.size())
       return false;
     return std::equal(search.begin(), search.end(), str.begin(),
                       chromium_CaseInsensitiveCompare<wchar_t>());
   }
 }
 
-DataUnits GetByteDisplayUnits(int64 bytes) {
+DataUnits GetByteDisplayUnits(int64_t bytes) {
   // The byte thresholds at which we display amounts.  A byte count is displayed
   // in unit U when kUnitThresholds[U] <= bytes < kUnitThresholds[U+1].
   // This must match the DataUnits enum.
-  static const int64 kUnitThresholds[] = {
+  static const int64_t kUnitThresholds[] = {
     0,              // DATA_UNITS_BYTE,
     3*1024,         // DATA_UNITS_KILOBYTE,
     2*1024*1024,    // DATA_UNITS_MEGABYTE,
     1024*1024*1024  // DATA_UNITS_GIGABYTE,
   };
 
   if (bytes < 0) {
     NOTREACHED() << "Negative bytes value";
@@ -758,17 +758,17 @@ static const wchar_t* const kByteStrings
 
 static const wchar_t* const kSpeedStrings[] = {
   L"B/s",
   L"kB/s",
   L"MB/s",
   L"GB/s"
 };
 
-std::wstring FormatBytesInternal(int64 bytes,
+std::wstring FormatBytesInternal(int64_t bytes,
                                  DataUnits units,
                                  bool show_units,
                                  const wchar_t* const* suffix) {
   if (bytes < 0) {
     NOTREACHED() << "Negative bytes value";
     return std::wstring();
   }
 
@@ -781,35 +781,35 @@ std::wstring FormatBytesInternal(int64 b
 
   wchar_t tmp[64];
   // If the first decimal digit is 0, don't show it.
   double int_part;
   double fractional_part = modf(unit_amount, &int_part);
   modf(fractional_part * 10, &int_part);
   if (int_part == 0) {
     base::swprintf(tmp, arraysize(tmp),
-                   L"%lld", static_cast<int64>(unit_amount));
+                   L"%lld", static_cast<int64_t>(unit_amount));
   } else {
     base::swprintf(tmp, arraysize(tmp), L"%.1lf", unit_amount);
   }
 
   std::wstring ret(tmp);
   if (show_units) {
     ret += L" ";
     ret += suffix[units];
   }
 
   return ret;
 }
 
-std::wstring FormatBytes(int64 bytes, DataUnits units, bool show_units) {
+std::wstring FormatBytes(int64_t bytes, DataUnits units, bool show_units) {
   return FormatBytesInternal(bytes, units, show_units, kByteStrings);
 }
 
-std::wstring FormatSpeed(int64 bytes, DataUnits units, bool show_units) {
+std::wstring FormatSpeed(int64_t bytes, DataUnits units, bool show_units) {
   return FormatBytesInternal(bytes, units, show_units, kSpeedStrings);
 }
 
 template<class StringType>
 void DoReplaceSubstringsAfterOffset(StringType* str,
                                     typename StringType::size_type start_offset,
                                     const StringType& find_this,
                                     const StringType& replace_with,
@@ -1029,30 +1029,30 @@ std::wstring IntToWString(int value) {
 std::string UintToString(unsigned int value) {
   return IntToStringT<std::string, unsigned int, unsigned int, false>::
       IntToString(value);
 }
 std::wstring UintToWString(unsigned int value) {
   return IntToStringT<std::wstring, unsigned int, unsigned int, false>::
       IntToString(value);
 }
-std::string Int64ToString(int64 value) {
-  return IntToStringT<std::string, int64, uint64, true>::
+std::string Int64ToString(int64_t value) {
+  return IntToStringT<std::string, int64_t, uint64_t, true>::
       IntToString(value);
 }
-std::wstring Int64ToWString(int64 value) {
-  return IntToStringT<std::wstring, int64, uint64, true>::
+std::wstring Int64ToWString(int64_t value) {
+  return IntToStringT<std::wstring, int64_t, uint64_t, true>::
       IntToString(value);
 }
-std::string Uint64ToString(uint64 value) {
-  return IntToStringT<std::string, uint64, uint64, false>::
+std::string Uint64ToString(uint64_t value) {
+  return IntToStringT<std::string, uint64_t, uint64_t, false>::
       IntToString(value);
 }
-std::wstring Uint64ToWString(uint64 value) {
-  return IntToStringT<std::wstring, uint64, uint64, false>::
+std::wstring Uint64ToWString(uint64_t value) {
+  return IntToStringT<std::wstring, uint64_t, uint64_t, false>::
       IntToString(value);
 }
 
 void StringAppendV(std::string* dst, const char* format, va_list ap) {
   StringAppendVT(dst, format, ap);
 }
 
 void StringAppendV(std::wstring* dst, const wchar_t* format, va_list ap) {
@@ -1452,21 +1452,21 @@ bool StringToInt(const string16& input, 
   if (!ok || tmp > kint32max) {
     return false;
   }
   *output = static_cast<int>(tmp);
   return true;
 }
 #endif //  !defined(ARCH_CPU_64_BITS)
 
-bool StringToInt64(const std::string& input, int64* output) {
+bool StringToInt64(const std::string& input, int64_t* output) {
   return StringToNumber<StringToInt64Traits>(input, output);
 }
 
-bool StringToInt64(const string16& input, int64* output) {
+bool StringToInt64(const string16& input, int64_t* output) {
   return StringToNumber<String16ToInt64Traits>(input, output);
 }
 
 #if !defined(ARCH_CPU_64_BITS)
 bool HexStringToInt(const std::string& input, int* output) {
   COMPILE_ASSERT(sizeof(int) == sizeof(long), cannot_strtol_to_int);
   return StringToNumber<HexStringToLongTraits>(input,
                                                reinterpret_cast<long*>(output));
@@ -1499,75 +1499,75 @@ bool HexStringToInt(const string16& inpu
   return true;
 }
 
 #endif // !defined(ARCH_CPU_64_BITS)
 
 namespace {
 
 template<class CHAR>
-bool HexDigitToIntT(const CHAR digit, uint8* val) {
+bool HexDigitToIntT(const CHAR digit, uint8_t* val) {
   if (digit >= '0' && digit <= '9')
     *val = digit - '0';
   else if (digit >= 'a' && digit <= 'f')
     *val = 10 + digit - 'a';
   else if (digit >= 'A' && digit <= 'F')
     *val = 10 + digit - 'A';
   else
     return false;
   return true;
 }
 
 template<typename STR>
-bool HexStringToBytesT(const STR& input, std::vector<uint8>* output) {
+bool HexStringToBytesT(const STR& input, std::vector<uint8_t>* output) {
   DCHECK(output->size() == 0);
   int count = input.size();
   if (count == 0 || (count % 2) != 0)
     return false;
   for (int i = 0; i < count / 2; ++i) {
-    uint8 msb = 0;  // most significant 4 bits
-    uint8 lsb = 0;  // least significant 4 bits
+    uint8_t msb = 0;  // most significant 4 bits
+    uint8_t lsb = 0;  // least significant 4 bits
     if (!HexDigitToIntT(input[i * 2], &msb) ||
         !HexDigitToIntT(input[i * 2 + 1], &lsb))
       return false;
     output->push_back((msb << 4) | lsb);
   }
   return true;
 }
 
 }  // namespace
 
-bool HexStringToBytes(const std::string& input, std::vector<uint8>* output) {
+bool HexStringToBytes(const std::string& input, std::vector<uint8_t>* output) {
   return HexStringToBytesT(input, output);
 }
 
-bool HexStringToBytes(const string16& input, std::vector<uint8>* output) {
+bool HexStringToBytes(const string16& input, std::vector<uint8_t>* output) {
   return HexStringToBytesT(input, output);
 }
 
 int StringToInt(const std::string& value) {
   int result;
   StringToInt(value, &result);
   return result;
 }
 
 int StringToInt(const string16& value) {
   int result;
   StringToInt(value, &result);
   return result;
 }
 
-int64 StringToInt64(const std::string& value) {
-  int64 result;
+int64_t StringToInt64(const std::string& value) {
+  int64_t result;
   StringToInt64(value, &result);
   return result;
 }
 
-int64 StringToInt64(const string16& value) {
-  int64 result;
+int64_t StringToInt64(const string16& value) {
+  int64_t result;
   StringToInt64(value, &result);
   return result;
 }
 
 int HexStringToInt(const std::string& value) {
   int result;
   HexStringToInt(value, &result);
   return result;
--- a/ipc/chromium/src/base/string_util.h
+++ b/ipc/chromium/src/base/string_util.h
@@ -353,32 +353,32 @@ enum DataUnits {
   DATA_UNITS_BYTE = 0,
   DATA_UNITS_KILOBYTE,
   DATA_UNITS_MEGABYTE,
   DATA_UNITS_GIGABYTE
 };
 
 // Return the unit type that is appropriate for displaying the amount of bytes
 // passed in.
-DataUnits GetByteDisplayUnits(int64 bytes);
+DataUnits GetByteDisplayUnits(int64_t bytes);
 
 // Return a byte string in human-readable format, displayed in units appropriate
 // specified by 'units', with an optional unit suffix.
 // Ex: FormatBytes(512, DATA_UNITS_KILOBYTE, true) => "0.5 KB"
 // Ex: FormatBytes(10*1024, DATA_UNITS_MEGABYTE, false) => "0.1"
-std::wstring FormatBytes(int64 bytes, DataUnits units, bool show_units);
+std::wstring FormatBytes(int64_t bytes, DataUnits units, bool show_units);
 
 // As above, but with "/s" units.
 // Ex: FormatSpeed(512, DATA_UNITS_KILOBYTE, true) => "0.5 KB/s"
 // Ex: FormatSpeed(10*1024, DATA_UNITS_MEGABYTE, false) => "0.1"
-std::wstring FormatSpeed(int64 bytes, DataUnits units, bool show_units);
+std::wstring FormatSpeed(int64_t bytes, DataUnits units, bool show_units);
 
 // Return a number formated with separators in the user's locale way.
 // Ex: FormatNumber(1234567) => 1,234,567
-std::wstring FormatNumber(int64 number);
+std::wstring FormatNumber(int64_t number);
 
 // Starting at |start_offset| (usually 0), replace the first instance of
 // |find_this| with |replace_with|.
 void ReplaceFirstSubstringAfterOffset(string16* str,
                                       string16::size_type start_offset,
                                       const string16& find_this,
                                       const string16& replace_with);
 void ReplaceFirstSubstringAfterOffset(std::string* str,
@@ -401,20 +401,20 @@ void ReplaceSubstringsAfterOffset(std::s
                                   const std::string& find_this,
                                   const std::string& replace_with);
 
 // Specialized string-conversion functions.
 std::string IntToString(int value);
 std::wstring IntToWString(int value);
 std::string UintToString(unsigned int value);
 std::wstring UintToWString(unsigned int value);
-std::string Int64ToString(int64 value);
-std::wstring Int64ToWString(int64 value);
-std::string Uint64ToString(uint64 value);
-std::wstring Uint64ToWString(uint64 value);
+std::string Int64ToString(int64_t value);
+std::wstring Int64ToWString(int64_t value);
+std::string Uint64ToString(uint64_t value);
+std::wstring Uint64ToWString(uint64_t value);
 // The DoubleToString methods convert the double to a string format that
 // ignores the locale.  If you want to use locale specific formatting, use ICU.
 std::string DoubleToString(double value);
 std::wstring DoubleToWString(double value);
 
 // Perform a best-effort conversion of the input string to a numeric type,
 // setting |*output| to the result of the conversion.  Returns true for
 // "perfect" conversions; returns false in the following cases:
@@ -422,44 +422,44 @@ std::wstring DoubleToWString(double valu
 //    by the data type.
 //  - Trailing characters in the string after parsing the number.  |*output|
 //    will be set to the value of the number that was parsed.
 //  - No characters parseable as a number at the beginning of the string.
 //    |*output| will be set to 0.
 //  - Empty string.  |*output| will be set to 0.
 bool StringToInt(const std::string& input, int* output);
 bool StringToInt(const string16& input, int* output);
-bool StringToInt64(const std::string& input, int64* output);
-bool StringToInt64(const string16& input, int64* output);
+bool StringToInt64(const std::string& input, int64_t* output);
+bool StringToInt64(const string16& input, int64_t* output);
 bool HexStringToInt(const std::string& input, int* output);
 bool HexStringToInt(const string16& input, int* output);
 
 // Similar to the previous functions, except that output is a vector of bytes.
 // |*output| will contain as many bytes as were successfully parsed prior to the
 // error.  There is no overflow, but input.size() must be evenly divisible by 2.
 // Leading 0x or +/- are not allowed.
-bool HexStringToBytes(const std::string& input, std::vector<uint8>* output);
-bool HexStringToBytes(const string16& input, std::vector<uint8>* output);
+bool HexStringToBytes(const std::string& input, std::vector<uint8_t>* output);
+bool HexStringToBytes(const string16& input, std::vector<uint8_t>* output);
 
 // For floating-point conversions, only conversions of input strings in decimal
 // form are defined to work.  Behavior with strings representing floating-point
 // numbers in hexadecimal, and strings representing non-fininte values (such as
 // NaN and inf) is undefined.  Otherwise, these behave the same as the integral
 // variants.  This expects the input string to NOT be specific to the locale.
 // If your input is locale specific, use ICU to read the number.
 bool StringToDouble(const std::string& input, double* output);
 bool StringToDouble(const string16& input, double* output);
 
 // Convenience forms of the above, when the caller is uninterested in the
 // boolean return value.  These return only the |*output| value from the
 // above conversions: a best-effort conversion when possible, otherwise, 0.
 int StringToInt(const std::string& value);
 int StringToInt(const string16& value);
-int64 StringToInt64(const std::string& value);
-int64 StringToInt64(const string16& value);
+int64_t StringToInt64(const std::string& value);
+int64_t StringToInt64(const string16& value);
 int HexStringToInt(const std::string& value);
 int HexStringToInt(const string16& value);
 double StringToDouble(const std::string& value);
 double StringToDouble(const string16& value);
 
 // Return a C++ string given printf-like input.
 std::string StringPrintf(const char* format, ...);
 std::wstring StringPrintf(const wchar_t* format, ...);
--- a/ipc/chromium/src/base/string_util_icu.cc
+++ b/ipc/chromium/src/base/string_util_icu.cc
@@ -20,36 +20,36 @@ namespace {
 
 // Reads a UTF-8 stream, placing the next code point into the given output
 // |*code_point|. |src| represents the entire string to read, and |*char_index|
 // is the character offset within the string to start reading at. |*char_index|
 // will be updated to index the last character read, such that incrementing it
 // (as in a for loop) will take the reader to the next character.
 //
 // Returns true on success. On false, |*code_point| will be invalid.
-bool ReadUnicodeCharacter(const char* src, int32 src_len,
-                          int32* char_index, uint32* code_point_out) {
+bool ReadUnicodeCharacter(const char* src, int32_t src_len,
+                          int32_t* char_index, uint32_t* code_point_out) {
   // U8_NEXT expects to be able to use -1 to signal an error, so we must
   // use a signed type for code_point.  But this function returns false
   // on error anyway, so code_point_out is unsigned.
-  int32 code_point;
+  int32_t code_point;
   U8_NEXT(src, *char_index, src_len, code_point);
-  *code_point_out = static_cast<uint32>(code_point);
+  *code_point_out = static_cast<uint32_t>(code_point);
 
   // The ICU macro above moves to the next char, we want to point to the last
   // char consumed.
   (*char_index)--;
 
   // Validate the decoded value.
   return U_IS_UNICODE_CHAR(code_point);
 }
 
 // Reads a UTF-16 character. The usage is the same as the 8-bit version above.
-bool ReadUnicodeCharacter(const char16* src, int32 src_len,
-                          int32* char_index, uint32* code_point) {
+bool ReadUnicodeCharacter(const char16* src, int32_t src_len,
+                          int32_t* char_index, uint32_t* code_point) {
   if (U16_IS_SURROGATE(src[*char_index])) {
     if (!U16_IS_SURROGATE_LEAD(src[*char_index]) ||
         *char_index + 1 >= src_len ||
         !U16_IS_TRAIL(src[*char_index + 1])) {
       // Invalid surrogate pair.
       return false;
     }
 
@@ -62,63 +62,63 @@ bool ReadUnicodeCharacter(const char16* 
     *code_point = src[*char_index];
   }
 
   return U_IS_UNICODE_CHAR(*code_point);
 }
 
 #if defined(WCHAR_T_IS_UTF32)
 // Reads UTF-32 character. The usage is the same as the 8-bit version above.
-bool ReadUnicodeCharacter(const wchar_t* src, int32 src_len,
-                        int32* char_index, uint32* code_point) {
+bool ReadUnicodeCharacter(const wchar_t* src, int32_t src_len,
+                        int32_t* char_index, uint32_t* code_point) {
   // Conversion is easy since the source is 32-bit.
   *code_point = src[*char_index];
 
   // Validate the value.
   return U_IS_UNICODE_CHAR(*code_point);
 }
 #endif  // defined(WCHAR_T_IS_UTF32)
 
 // WriteUnicodeCharacter -------------------------------------------------------
 
 // Appends a UTF-8 character to the given 8-bit string.
-void WriteUnicodeCharacter(uint32 code_point, std::string* output) {
+void WriteUnicodeCharacter(uint32_t code_point, std::string* output) {
   if (code_point <= 0x7f) {
     // Fast path the common case of one byte.
     output->push_back(code_point);
     return;
   }
 
   // U8_APPEND_UNSAFE can append up to 4 bytes.
-  int32 char_offset = static_cast<int32>(output->length());
+  int32_t char_offset = static_cast<int32_t>(output->length());
   output->resize(char_offset + U8_MAX_LENGTH);
 
   U8_APPEND_UNSAFE(&(*output)[0], char_offset, code_point);
 
   // U8_APPEND_UNSAFE will advance our pointer past the inserted character, so
   // it will represent the new length of the string.
   output->resize(char_offset);
 }
 
 // Appends the given code point as a UTF-16 character to the STL string.
-void WriteUnicodeCharacter(uint32 code_point, string16* output) {
+void WriteUnicodeCharacter(uint32_t code_point, string16* output) {
   if (U16_LENGTH(code_point) == 1) {
     // Thie code point is in the Basic Multilingual Plane (BMP).
     output->push_back(static_cast<char16>(code_point));
   } else {
     // Non-BMP characters use a double-character encoding.
-    int32 char_offset = static_cast<int32>(output->length());
+    int32_t char_offset = static_cast<int32_t>(output->length());
     output->resize(char_offset + U16_MAX_LENGTH);
     U16_APPEND_UNSAFE(&(*output)[0], char_offset, code_point);
   }
 }
 
 #if defined(WCHAR_T_IS_UTF32)
 // Appends the given UTF-32 character to the given 32-bit string.
-inline void WriteUnicodeCharacter(uint32 code_point, std::wstring* output) {
+inline void WriteUnicodeCharacter(uint32_t code_point, std::wstring* output) {
   // This is the easy case, just append the character.
   output->push_back(code_point);
 }
 #endif  // defined(WCHAR_T_IS_UTF32)
 
 // Generalized Unicode converter -----------------------------------------------
 
 // Converts the given source Unicode character type to the given destination
@@ -126,19 +126,19 @@ inline void WriteUnicodeCharacter(uint32
 // determine the source, and the given output STL string will be replaced by
 // the result.
 template<typename SRC_CHAR, typename DEST_STRING>
 bool ConvertUnicode(const SRC_CHAR* src, size_t src_len, DEST_STRING* output) {
   output->clear();
 
   // ICU requires 32-bit numbers.
   bool success = true;
-  int32 src_len32 = static_cast<int32>(src_len);
-  for (int32 i = 0; i < src_len32; i++) {
-    uint32 code_point;
+  int32_t src_len32 = static_cast<int32_t>(src_len);
+  for (int32_t i = 0; i < src_len32; i++) {
+    uint32_t code_point;
     if (ReadUnicodeCharacter(src, src_len32, &i, &code_point))
       WriteUnicodeCharacter(code_point, output);
     else
       success = false;
   }
   return success;
 }
 
@@ -496,32 +496,32 @@ struct NumberFormatSingletonTraits
   // There's no ICU call to destroy a NumberFormat object other than
   // operator delete, so use the default Delete, which calls operator delete.
   // This can cause problems if a different allocator is used by this file than
   // by ICU.
 };
 
 }  // namespace
 
-std::wstring FormatNumber(int64 number) {
+std::wstring FormatNumber(int64_t number) {
   NumberFormat* number_format =
       Singleton<NumberFormat, NumberFormatSingletonTraits>::get();
 
   if (!number_format) {
     // As a fallback, just return the raw number in a string.
     return StringPrintf(L"%lld", number);
   }
   UnicodeString ustr;
   number_format->format(number, ustr);
 
 #if defined(WCHAR_T_IS_UTF16)
   return std::wstring(ustr.getBuffer(),
                       static_cast<std::wstring::size_type>(ustr.length()));
 #elif defined(WCHAR_T_IS_UTF32)
-  wchar_t buffer[64];  // A int64 is less than 20 chars long,  so 64 chars
+  wchar_t buffer[64];  // A int64_t is less than 20 chars long,  so 64 chars
                        // leaves plenty of room for formating stuff.
   int length = 0;
   UErrorCode error = U_ZERO_ERROR;
   u_strToWCS(buffer, 64, &length, ustr.getBuffer(), ustr.length() , &error);
   if (U_FAILURE(error)) {
     NOTREACHED();
     // As a fallback, just return the raw number in a string.
     return StringPrintf(L"%lld", number);
--- a/ipc/chromium/src/base/string_util_unittest.cc
+++ b/ipc/chromium/src/base/string_util_unittest.cc
@@ -661,17 +661,17 @@ TEST(StringUtilTest, LowerCaseEqualsASCI
                                      lowercase_cases[i].dst));
     EXPECT_TRUE(LowerCaseEqualsASCII(lowercase_cases[i].src_a,
                                      lowercase_cases[i].dst));
   }
 }
 
 TEST(StringUtilTest, GetByteDisplayUnits) {
   static const struct {
-    int64 bytes;
+    int64_t bytes;
     DataUnits expected;
   } cases[] = {
     {0, DATA_UNITS_BYTE},
     {512, DATA_UNITS_BYTE},
     {10*1024, DATA_UNITS_KILOBYTE},
     {10*1024*1024, DATA_UNITS_MEGABYTE},
     {10LL*1024*1024*1024, DATA_UNITS_GIGABYTE},
     {~(1LL<<63), DATA_UNITS_GIGABYTE},
@@ -681,17 +681,17 @@ TEST(StringUtilTest, GetByteDisplayUnits
   };
 
   for (size_t i = 0; i < ARRAYSIZE_UNSAFE(cases); ++i)
     EXPECT_EQ(cases[i].expected, GetByteDisplayUnits(cases[i].bytes));
 }
 
 TEST(StringUtilTest, FormatBytes) {
   static const struct {
-    int64 bytes;
+    int64_t bytes;
     DataUnits units;
     const wchar_t* expected;
     const wchar_t* expected_with_units;
   } cases[] = {
     {0, DATA_UNITS_BYTE, L"0", L"0 B"},
     {512, DATA_UNITS_BYTE, L"512", L"512 B"},
     {512, DATA_UNITS_KILOBYTE, L"0.5", L"0.5 kB"},
     {1024*1024, DATA_UNITS_KILOBYTE, L"1024", L"1024 kB"},
@@ -793,46 +793,46 @@ struct IntToStringTest {
 TEST(StringUtilTest, IntToString) {
 
   static const IntToStringTest<int> int_tests[] = {
       { 0, "0", "0" },
       { -1, "-1", "4294967295" },
       { std::numeric_limits<int>::max(), "2147483647", "2147483647" },
       { std::numeric_limits<int>::min(), "-2147483648", "2147483648" },
   };
-  static const IntToStringTest<int64> int64_tests[] = {
+  static const IntToStringTest<int64_t> int64_tests[] = {
       { 0, "0", "0" },
       { -1, "-1", "18446744073709551615" },
-      { std::numeric_limits<int64>::max(),
+      { std::numeric_limits<int64_t>::max(),
         "9223372036854775807",
         "9223372036854775807", },
-      { std::numeric_limits<int64>::min(),
+      { std::numeric_limits<int64_t>::min(),
         "-9223372036854775808",
         "9223372036854775808" },
   };
 
   for (size_t i = 0; i < arraysize(int_tests); ++i) {
     const IntToStringTest<int>* test = &int_tests[i];
     EXPECT_EQ(IntToString(test->num), test->sexpected);
     EXPECT_EQ(IntToWString(test->num), UTF8ToWide(test->sexpected));
     EXPECT_EQ(UintToString(test->num), test->uexpected);
     EXPECT_EQ(UintToWString(test->num), UTF8ToWide(test->uexpected));
   }
   for (size_t i = 0; i < arraysize(int64_tests); ++i) {
-    const IntToStringTest<int64>* test = &int64_tests[i];
+    const IntToStringTest<int64_t>* test = &int64_tests[i];
     EXPECT_EQ(Int64ToString(test->num), test->sexpected);
     EXPECT_EQ(Int64ToWString(test->num), UTF8ToWide(test->sexpected));
     EXPECT_EQ(Uint64ToString(test->num), test->uexpected);
     EXPECT_EQ(Uint64ToWString(test->num), UTF8ToWide(test->uexpected));
   }
 }
 
 TEST(StringUtilTest, Uint64ToString) {
   static const struct {
-    uint64 input;
+    uint64_t input;
     std::string output;
   } cases[] = {
     {0, "0"},
     {42, "42"},
     {INT_MAX, "2147483647"},
     {kuint64max, "18446744073709551615"},
   };
 
@@ -895,17 +895,17 @@ TEST(StringUtilTest, StringToInt) {
   std::wstring wide_input = ASCIIToWide(input_string);
   EXPECT_FALSE(StringToInt(WideToUTF16Hack(wide_input), &output));
   EXPECT_EQ(6, output);
 }
 
 TEST(StringUtilTest, StringToInt64) {
   static const struct {
     std::string input;
-    int64 output;
+    int64_t output;
     bool success;
   } cases[] = {
     {"0", 0, true},
     {"42", 42, true},
     {"-2147483648", INT_MIN, true},
     {"2147483647", INT_MAX, true},
     {"-2147483649", GG_INT64_C(-2147483649), true},
     {"-99999999999", GG_INT64_C(-99999999999), true},
@@ -932,33 +932,33 @@ TEST(StringUtilTest, StringToInt64) {
     {"-9223372036854775809", kint64min, false},
     {"-99999999999999999999", kint64min, false},
     {"9223372036854775808", kint64max, false},
     {"99999999999999999999", kint64max, false},
   };
 
   for (size_t i = 0; i < ARRAYSIZE_UNSAFE(cases); ++i) {
     EXPECT_EQ(cases[i].output, StringToInt64(cases[i].input));
-    int64 output;
+    int64_t output;
     EXPECT_EQ(cases[i].success, StringToInt64(cases[i].input, &output));
     EXPECT_EQ(cases[i].output, output);
 
     std::wstring wide_input = ASCIIToWide(cases[i].input);
     EXPECT_EQ(cases[i].output, StringToInt64(WideToUTF16Hack(wide_input)));
     EXPECT_EQ(cases[i].success, StringToInt64(WideToUTF16Hack(wide_input),
                                               &output));
     EXPECT_EQ(cases[i].output, output);
   }
 
   // One additional test to verify that conversion of numbers in strings with
   // embedded NUL characters.  The NUL and extra data after it should be
   // interpreted as junk after the number.
   const char input[] = "6\06";
   std::string input_string(input, arraysize(input) - 1);
-  int64 output;
+  int64_t output;
   EXPECT_FALSE(StringToInt64(input_string, &output));
   EXPECT_EQ(6, output);
 
   std::wstring wide_input = ASCIIToWide(input_string);
   EXPECT_FALSE(StringToInt64(WideToUTF16Hack(wide_input), &output));
   EXPECT_EQ(6, output);
 }
 
@@ -1046,35 +1046,35 @@ TEST(StringUtilTest, HexStringToBytes) {
     {"", "", 0, false},
     {"0123456789ABCDEF", "\x01\x23\x45\x67\x89\xAB\xCD\xEF", 8, true},
     {"0123456789ABCDEF012345",
      "\x01\x23\x45\x67\x89\xAB\xCD\xEF\x01\x23\x45", 11, true},
   };
 
 
   for (size_t i = 0; i < ARRAYSIZE_UNSAFE(cases); ++i) {
-    std::vector<uint8> output;
-    std::vector<uint8> compare;
+    std::vector<uint8_t> output;
+    std::vector<uint8_t> compare;
     EXPECT_EQ(cases[i].success, HexStringToBytes(cases[i].input, &output)) <<
         i << ": " << cases[i].input;
     for (size_t j = 0; j < cases[i].output_len; ++j)
-      compare.push_back(static_cast<uint8>(cases[i].output[j]));
+      compare.push_back(static_cast<uint8_t>(cases[i].output[j]));
     ASSERT_EQ(output.size(), compare.size()) << i << ": " << cases[i].input;
     EXPECT_TRUE(std::equal(output.begin(), output.end(), compare.begin())) <<
         i << ": " << cases[i].input;
 
     output.clear();
     compare.clear();
 
     std::wstring wide_input = ASCIIToWide(cases[i].input);
     EXPECT_EQ(cases[i].success,
               HexStringToBytes(WideToUTF16Hack(wide_input), &output)) <<
         i << ": " << cases[i].input;
     for (size_t j = 0; j < cases[i].output_len; ++j)
-      compare.push_back(static_cast<uint8>(cases[i].output[j]));
+      compare.push_back(static_cast<uint8_t>(cases[i].output[j]));
     ASSERT_EQ(output.size(), compare.size()) << i << ": " << cases[i].input;
     EXPECT_TRUE(std::equal(output.begin(), output.end(), compare.begin())) <<
         i << ": " << cases[i].input;
   }
 }
 
 TEST(StringUtilTest, StringToDouble) {
   static const struct {
--- a/ipc/chromium/src/base/sys_info.h
+++ b/ipc/chromium/src/base/sys_info.h
@@ -14,26 +14,26 @@ namespace base {
 class SysInfo {
  public:
   // Return the number of logical processors/cores on the current machine.
   // WARNING: On POSIX, this method uses static variables and is not threadsafe
   // until it's been initialized by being called once without a race.
   static int NumberOfProcessors();
 
   // Return the number of bytes of physical memory on the current machine.
-  static int64 AmountOfPhysicalMemory();
+  static int64_t AmountOfPhysicalMemory();
 
   // Return the number of megabytes of physical memory on the current machine.
   static int AmountOfPhysicalMemoryMB() {
     return static_cast<int>(AmountOfPhysicalMemory() / 1024 / 1024);
   }
 
   // Return the available disk space in bytes on the volume containing |path|,
   // or -1 on failure.
-  static int64 AmountOfFreeDiskSpace(const std::wstring& path);
+  static int64_t AmountOfFreeDiskSpace(const std::wstring& path);
 
   // Return true if the given environment variable is defined.
   // TODO: find a better place for HasEnvVar.
   static bool HasEnvVar(const wchar_t* var);
 
   // Return the value of the given environment variable
   // or an empty string if not defined.
   // TODO: find a better place for GetEnvVar.
@@ -45,19 +45,19 @@ class SysInfo {
   // Returns the version of the host operating system.
   static std::string OperatingSystemVersion();
 
   // Retrieves detailed numeric values for the OS version.
   // WARNING: On OS X, this method uses static variables and is not threadsafe
   // until it's been initialized by being called once without a race.
   // TODO(port): Implement a Linux version of this method and enable the
   // corresponding unit test.
-  static void OperatingSystemVersionNumbers(int32 *major_version,
-                                            int32 *minor_version,
-                                            int32 *bugfix_version);
+  static void OperatingSystemVersionNumbers(int32_t *major_version,
+                                            int32_t *minor_version,
+                                            int32_t *bugfix_version);
 
   // Returns the CPU architecture of the system. Exact return value may differ
   // across platforms.
   static std::string CPUArchitecture();
 
   // Returns the pixel dimensions of the primary display via the
   // width and height parameters.
   static void GetPrimaryDisplayDimensions(int* width, int* height);
--- a/ipc/chromium/src/base/sys_info_mac.cc
+++ b/ipc/chromium/src/base/sys_info_mac.cc
@@ -4,23 +4,23 @@
 
 #include "base/sys_info.h"
 
 #include <CoreServices/CoreServices.h>
 
 namespace base {
 
 // static
-void SysInfo::OperatingSystemVersionNumbers(int32 *major_version,
-                                            int32 *minor_version,
-                                            int32 *bugfix_version) {
+void SysInfo::OperatingSystemVersionNumbers(int32_t *major_version,
+                                            int32_t *minor_version,
+                                            int32_t *bugfix_version) {
   static bool is_initialized = false;
-  static int32 major_version_cached = 0;
-  static int32 minor_version_cached = 0;
-  static int32 bugfix_version_cached = 0;
+  static int32_t major_version_cached = 0;
+  static int32_t minor_version_cached = 0;
+  static int32_t bugfix_version_cached = 0;
 
   if (!is_initialized) {
     // Gestalt can't be called in the sandbox, so we cache its return value.
     Gestalt(gestaltSystemVersionMajor,
         reinterpret_cast<SInt32*>(&major_version_cached));
     Gestalt(gestaltSystemVersionMinor,
         reinterpret_cast<SInt32*>(&minor_version_cached));
     Gestalt(gestaltSystemVersionBugFix,
@@ -34,13 +34,13 @@ void SysInfo::OperatingSystemVersionNumb
 }
 
 // static
 void SysInfo::CacheSysInfo() {
   // Due to startup time concerns [premature optimization?] we only cache values
   // from functions we know to be called in the renderer & fail when the sandbox
   // is enabled.
   NumberOfProcessors();
-  int32 dummy;
+  int32_t dummy;
   OperatingSystemVersionNumbers(&dummy, &dummy, &dummy);
 }
 
 }  // namespace base
--- a/ipc/chromium/src/base/sys_info_posix.cc
+++ b/ipc/chromium/src/base/sys_info_posix.cc
@@ -40,32 +40,32 @@ int SysInfo::NumberOfProcessors() {
     NOTREACHED();
     return 1;
   }
 
   return static_cast<int>(res);
 }
 
 // static
-int64 SysInfo::AmountOfPhysicalMemory() {
+int64_t SysInfo::AmountOfPhysicalMemory() {
   // _SC_PHYS_PAGES is not part of POSIX and not available on OS X
 #if defined(OS_MACOSX)
   struct host_basic_info hostinfo;
   mach_msg_type_number_t count = HOST_BASIC_INFO_COUNT;
   int result = host_info(mach_host_self(),
                          HOST_BASIC_INFO,
                          reinterpret_cast<host_info_t>(&hostinfo),
                          &count);
   DCHECK_EQ(HOST_BASIC_INFO_COUNT, count);
   if (result != KERN_SUCCESS) {
     NOTREACHED();
     return 0;
   }
 
-  return static_cast<int64>(hostinfo.max_mem);
+  return static_cast<int64_t>(hostinfo.max_mem);
 #elif defined(OS_NETBSD)
   int mib[2];
   int rc;
   int64_t memSize;
   size_t len = sizeof(memSize);
 
   mib[0] = CTL_HW;
   mib[1] = HW_PHYSMEM64;
@@ -78,28 +78,28 @@ int64 SysInfo::AmountOfPhysicalMemory() 
 #else
   long pages = sysconf(_SC_PHYS_PAGES);
   long page_size = sysconf(_SC_PAGE_SIZE);
   if (pages == -1 || page_size == -1) {
     NOTREACHED();
     return 0;
   }
 
-  return static_cast<int64>(pages) * page_size;
+  return static_cast<int64_t>(pages) * page_size;
 #endif
 }
 
 // static
-int64 SysInfo::AmountOfFreeDiskSpace(const std::wstring& path) {
+int64_t SysInfo::AmountOfFreeDiskSpace(const std::wstring& path) {
 #ifndef ANDROID
   struct statvfs stats;
   if (statvfs(WideToUTF8(path).c_str(), &stats) != 0) {
     return -1;
   }
-  return static_cast<int64>(stats.f_bavail) * stats.f_frsize;
+  return static_cast<int64_t>(stats.f_bavail) * stats.f_frsize;
 #else
   return -1;
 #endif
 }
 
 // static
 bool SysInfo::HasEnvVar(const wchar_t* var) {
   std::string var_utf8 = WideToUTF8(std::wstring(var));
--- a/ipc/chromium/src/base/sys_info_unittest.cc
+++ b/ipc/chromium/src/base/sys_info_unittest.cc
@@ -36,19 +36,19 @@ TEST_F(SysInfoTest, HasEnvVar) {
   // Every setup should have PATH...
   EXPECT_TRUE(base::SysInfo::HasEnvVar(L"PATH"));
 }
 
 // TODO(port): If and when there's a LINUX version of this method, enable this
 // unit test.
 #if defined(OS_WIN) || defined(OS_MACOSX)
 TEST_F(SysInfoTest, OperatingSystemVersionNumbers) {
-  int32 os_major_version = -1;
-  int32 os_minor_version = -1;
-  int32 os_bugfix_version = -1;
+  int32_t os_major_version = -1;
+  int32_t os_minor_version = -1;
+  int32_t os_bugfix_version = -1;
   base::SysInfo::OperatingSystemVersionNumbers(&os_major_version,
                                                &os_minor_version,
                                                &os_bugfix_version);
   EXPECT_GT(os_major_version, -1);
   EXPECT_GT(os_minor_version, -1);
   EXPECT_GT(os_bugfix_version, -1);
 }
 #endif  // OS_WIN || OS_MACOSX
--- a/ipc/chromium/src/base/sys_info_win.cc
+++ b/ipc/chromium/src/base/sys_info_win.cc
@@ -15,37 +15,37 @@ namespace base {
 // static
 int SysInfo::NumberOfProcessors() {
   SYSTEM_INFO info;
   GetSystemInfo(&info);
   return static_cast<int>(info.dwNumberOfProcessors);
 }
 
 // static
-int64 SysInfo::AmountOfPhysicalMemory() {
+int64_t SysInfo::AmountOfPhysicalMemory() {
   MEMORYSTATUSEX memory_info;
   memory_info.dwLength = sizeof(memory_info);
   if (!GlobalMemoryStatusEx(&memory_info)) {
     NOTREACHED();
     return 0;
   }
 
-  int64 rv = static_cast<int64>(memory_info.ullTotalPhys);
+  int64_t rv = static_cast<int64_t>(memory_info.ullTotalPhys);
   if (rv < 0)
     rv = kint64max;
   return rv;
 }
 
 // static
-int64 SysInfo::AmountOfFreeDiskSpace(const std::wstring& path) {
+int64_t SysInfo::AmountOfFreeDiskSpace(const std::wstring& path) {
   ULARGE_INTEGER available, total, free;
   if (!GetDiskFreeSpaceExW(path.c_str(), &available, &total, &free)) {
     return -1;
   }
-  int64 rv = static_cast<int64>(available.QuadPart);
+  int64_t rv = static_cast<int64_t>(available.QuadPart);
   if (rv < 0)
     rv = kint64max;
   return rv;
 }
 
 // static
 bool SysInfo::HasEnvVar(const wchar_t* var) {
   return GetEnvironmentVariable(var, NULL, 0) != 0;
@@ -104,19 +104,19 @@ int SysInfo::DisplayCount() {
 size_t SysInfo::VMAllocationGranularity() {
   SYSTEM_INFO sysinfo;
   GetSystemInfo(&sysinfo);
 
   return sysinfo.dwAllocationGranularity;
 }
 
 // static
-void SysInfo::OperatingSystemVersionNumbers(int32 *major_version,
-                                            int32 *minor_version,
-                                            int32 *bugfix_version) {
+void SysInfo::OperatingSystemVersionNumbers(int32_t *major_version,
+                                            int32_t *minor_version,
+                                            int32_t *bugfix_version) {
   OSVERSIONINFO info = {0};
   info.dwOSVersionInfoSize = sizeof(info);
   GetVersionEx(&info);
   *major_version = info.dwMajorVersion;
   *minor_version = info.dwMinorVersion;
   *bugfix_version = 0;
 }
 
--- a/ipc/chromium/src/base/sys_string_conversions.h
+++ b/ipc/chromium/src/base/sys_string_conversions.h
@@ -39,18 +39,18 @@ std::wstring SysNativeMBToWide(const Str
 
 // Windows-specific ------------------------------------------------------------
 
 #if defined(OS_WIN)
 
 // Converts between 8-bit and wide strings, using the given code page. The
 // code page identifier is one accepted by the Windows function
 // MultiByteToWideChar().
-std::wstring SysMultiByteToWide(const StringPiece& mb, uint32 code_page);
-std::string SysWideToMultiByte(const std::wstring& wide, uint32 code_page);
+std::wstring SysMultiByteToWide(const StringPiece& mb, uint32_t code_page);
+std::string SysWideToMultiByte(const std::wstring& wide, uint32_t code_page);
 
 #endif  // defined(OS_WIN)
 
 // Mac-specific ----------------------------------------------------------------
 
 #if defined(OS_MACOSX)
 
 // Converts between STL strings and CFStringRefs/NSStrings.
--- a/ipc/chromium/src/base/sys_string_conversions_win.cc
+++ b/ipc/chromium/src/base/sys_string_conversions_win.cc
@@ -24,17 +24,17 @@ std::string SysWideToNativeMB(const std:
   return SysWideToMultiByte(wide, CP_ACP);
 }
 
 std::wstring SysNativeMBToWide(const StringPiece& native_mb) {
   return SysMultiByteToWide(native_mb, CP_ACP);
 }
 
 // Do not assert in this function since it is used by the asssertion code!
-std::wstring SysMultiByteToWide(const StringPiece& mb, uint32 code_page) {
+std::wstring SysMultiByteToWide(const StringPiece& mb, uint32_t code_page) {
   if (mb.empty())
     return std::wstring();
 
   int mb_length = static_cast<int>(mb.length());
   // Compute the length of the buffer.
   int charcount = MultiByteToWideChar(code_page, 0,
                                       mb.data(), mb_length, NULL, 0);
   if (charcount == 0)
@@ -43,17 +43,17 @@ std::wstring SysMultiByteToWide(const St
   std::wstring wide;
   wide.resize(charcount);
   MultiByteToWideChar(code_page, 0, mb.data(), mb_length, &wide[0], charcount);
 
   return wide;
 }
 
 // Do not assert in this function since it is used by the asssertion code!
-std::string SysWideToMultiByte(const std::wstring& wide, uint32 code_page) {
+std::string SysWideToMultiByte(const std::wstring& wide, uint32_t code_page) {
   int wide_length = static_cast<int>(wide.length());
   if (wide_length == 0)
     return std::string();
 
   // Compute the length of the buffer we'll need.
   int charcount = WideCharToMultiByte(code_page, 0, wide.data(), wide_length,
                                       NULL, 0, NULL, NULL);
   if (charcount == 0)
--- a/ipc/chromium/src/base/test_file_util_mac.cc
+++ b/ipc/chromium/src/base/test_file_util_mac.cc
@@ -18,17 +18,17 @@ bool EvictFileFromSystemCache(const File
   // open should then have to load the file from disk.
 
   file_util::MemoryMappedFile mapped_file;
   if (!mapped_file.Initialize(file)) {
     DLOG(WARNING) << "failed to memory map " << file.value();
     return false;
   }
   
-  if (msync(const_cast<uint8*>(mapped_file.data()), mapped_file.length(),
+  if (msync(const_cast<uint8_t*>(mapped_file.data()), mapped_file.length(),
             MS_INVALIDATE) != 0) {
     DLOG(WARNING) << "failed to invalidate memory map of " << file.value() 
         << ", errno: " << errno;
     return false;
   }
   
   return true;
 }
--- a/ipc/chromium/src/base/time.cc
+++ b/ipc/chromium/src/base/time.cc
@@ -24,29 +24,29 @@ int TimeDelta::InHours() const {
 int TimeDelta::InMinutes() const {
   return static_cast<int>(delta_ / Time::kMicrosecondsPerMinute);
 }
 
 double TimeDelta::InSecondsF() const {
   return static_cast<double>(delta_) / Time::kMicrosecondsPerSecond;
 }
 
-int64 TimeDelta::InSeconds() const {
+int64_t TimeDelta::InSeconds() const {
   return delta_ / Time::kMicrosecondsPerSecond;
 }
 
 double TimeDelta::InMillisecondsF() const {
   return static_cast<double>(delta_) / Time::kMicrosecondsPerMillisecond;
 }
 
-int64 TimeDelta::InMilliseconds() const {
+int64_t TimeDelta::InMilliseconds() const {
   return delta_ / Time::kMicrosecondsPerMillisecond;
 }
 
-int64 TimeDelta::InMicroseconds() const {
+int64_t TimeDelta::InMicroseconds() const {
   return delta_;
 }
 
 // Time -----------------------------------------------------------------------
 
 // static
 Time Time::FromTimeT(time_t tt) {
   if (tt == 0)
--- a/ipc/chromium/src/base/time.h
+++ b/ipc/chromium/src/base/time.h
@@ -43,40 +43,40 @@ class PageLoadTrackerUnitTest;
 // TimeDelta ------------------------------------------------------------------
 
 class TimeDelta {
  public:
   TimeDelta() : delta_(0) {
   }
 
   // Converts units of time to TimeDeltas.
-  static TimeDelta FromDays(int64 days);
-  static TimeDelta FromHours(int64 hours);
-  static TimeDelta FromMinutes(int64 minutes);
-  static TimeDelta FromSeconds(int64 secs);
-  static TimeDelta FromMilliseconds(int64 ms);
-  static TimeDelta FromMicroseconds(int64 us);
+  static TimeDelta FromDays(int64_t days);
+  static TimeDelta FromHours(int64_t hours);
+  static TimeDelta FromMinutes(int64_t minutes);
+  static TimeDelta FromSeconds(int64_t secs);
+  static TimeDelta FromMilliseconds(int64_t ms);
+  static TimeDelta FromMicroseconds(int64_t us);
 
   // Returns the internal numeric value of the TimeDelta object. Please don't
   // use this and do arithmetic on it, as it is more error prone than using the
   // provided operators.
-  int64 ToInternalValue() const {
+  int64_t ToInternalValue() const {
     return delta_;
   }
 
   // Returns the time delta in some unit. The F versions return a floating
   // point value, the "regular" versions return a rounded-down value.
   int InDays() const;
   int InHours() const;
   int InMinutes() const;
   double InSecondsF() const;
-  int64 InSeconds() const;
+  int64_t InSeconds() const;
   double InMillisecondsF() const;
-  int64 InMilliseconds() const;
-  int64 InMicroseconds() const;
+  int64_t InMilliseconds() const;
+  int64_t InMicroseconds() const;
 
   TimeDelta& operator=(TimeDelta other) {
     delta_ = other.delta_;
     return *this;
   }
 
   // Computations with other deltas.
   TimeDelta operator+(TimeDelta other) const {
@@ -95,31 +95,31 @@ class TimeDelta {
     return *this;
   }
   TimeDelta operator-() const {
     return TimeDelta(-delta_);
   }
 
   // Computations with ints, note that we only allow multiplicative operations
   // with ints, and additive operations with other deltas.
-  TimeDelta operator*(int64 a) const {
+  TimeDelta operator*(int64_t a) const {
     return TimeDelta(delta_ * a);
   }
-  TimeDelta operator/(int64 a) const {
+  TimeDelta operator/(int64_t a) const {
     return TimeDelta(delta_ / a);
   }
-  TimeDelta& operator*=(int64 a) {
+  TimeDelta& operator*=(int64_t a) {
     delta_ *= a;
     return *this;
   }
-  TimeDelta& operator/=(int64 a) {
+  TimeDelta& operator/=(int64_t a) {
     delta_ /= a;
     return *this;
   }
-  int64 operator/(TimeDelta a) const {
+  int64_t operator/(TimeDelta a) const {
     return delta_ / a.delta_;
   }
 
   // Defined below because it depends on the definition of the other classes.
   Time operator+(Time t) const;
   TimeTicks operator+(TimeTicks t) const;
 
   // Comparison operators.
@@ -140,47 +140,47 @@ class TimeDelta {
   }
   bool operator>=(TimeDelta other) const {
     return delta_ >= other.delta_;
   }
 
  private:
   friend class Time;
   friend class TimeTicks;
-  friend TimeDelta operator*(int64 a, TimeDelta td);
+  friend TimeDelta operator*(int64_t a, TimeDelta td);
 
   // Constructs a delta given the duration in microseconds. This is private
   // to avoid confusion by callers with an integer constructor. Use
   // FromSeconds, FromMilliseconds, etc. instead.
-  explicit TimeDelta(int64 delta_us) : delta_(delta_us) {
+  explicit TimeDelta(int64_t delta_us) : delta_(delta_us) {
   }
 
   // Delta in microseconds.
-  int64 delta_;
+  int64_t delta_;
 };
 
-inline TimeDelta operator*(int64 a, TimeDelta td) {
+inline TimeDelta operator*(int64_t a, TimeDelta td) {
   return TimeDelta(a * td.delta_);
 }
 
 // Time -----------------------------------------------------------------------
 
 // Represents a wall clock time.
 class Time {
  public:
-  static const int64 kMillisecondsPerSecond = 1000;
-  static const int64 kMicrosecondsPerMillisecond = 1000;
-  static const int64 kMicrosecondsPerSecond = kMicrosecondsPerMillisecond *
+  static const int64_t kMillisecondsPerSecond = 1000;
+  static const int64_t kMicrosecondsPerMillisecond = 1000;
+  static const int64_t kMicrosecondsPerSecond = kMicrosecondsPerMillisecond *
                                               kMillisecondsPerSecond;
-  static const int64 kMicrosecondsPerMinute = kMicrosecondsPerSecond * 60;
-  static const int64 kMicrosecondsPerHour = kMicrosecondsPerMinute * 60;
-  static const int64 kMicrosecondsPerDay = kMicrosecondsPerHour * 24;
-  static const int64 kMicrosecondsPerWeek = kMicrosecondsPerDay * 7;
-  static const int64 kNanosecondsPerMicrosecond = 1000;
-  static const int64 kNanosecondsPerSecond = kNanosecondsPerMicrosecond *
+  static const int64_t kMicrosecondsPerMinute = kMicrosecondsPerSecond * 60;
+  static const int64_t kMicrosecondsPerHour = kMicrosecondsPerMinute * 60;
+  static const int64_t kMicrosecondsPerDay = kMicrosecondsPerHour * 24;
+  static const int64_t kMicrosecondsPerWeek = kMicrosecondsPerDay * 7;
+  static const int64_t kNanosecondsPerMicrosecond = 1000;
+  static const int64_t kNanosecondsPerSecond = kNanosecondsPerMicrosecond *
                                              kMicrosecondsPerSecond;
 
   // Represents an exploded time that can be formatted nicely. This is kind of
   // like the Win32 SYSTEMTIME structure or the Unix "struct tm" with a few
   // additions and changes to prevent errors.
   struct Exploded {
     int year;                 // Four digit year "2007"
     signed char month;        // 1-based month (values 1 = January, etc.)
@@ -238,32 +238,32 @@ class Time {
   static Time FromLocalExploded(const Exploded& exploded) {
     return FromExploded(true, exploded);
   }
 
   // Converts an integer value representing Time to a class. This is used
   // when deserializing a |Time| structure, using a value known to be
   // compatible. It is not provided as a constructor because the integer type
   // may be unclear from the perspective of a caller.
-  static Time FromInternalValue(int64 us) {
+  static Time FromInternalValue(int64_t us) {
     return Time(us);
   }
 
   // Converts a string representation of time to a Time object.
   // An example of a time string which is converted is as below:-
   // "Tue, 15 Nov 1994 12:45:26 GMT". If the timezone is not specified
   // in the input string, we assume local time.
   // TODO(iyengar) Move the FromString/FromTimeT/ToTimeT/FromFileTime to
   // a new time converter class.
   static bool FromString(const wchar_t* time_string, Time* parsed_time);
 
   // For serializing, use FromInternalValue to reconstitute. Please don't use
   // this and do arithmetic on it, as it is more error prone than using the
   // provided operators.
-  int64 ToInternalValue() const {
+  int64_t ToInternalValue() const {
     return us_;
   }
 
   // Fills the given exploded structure with either the local time or UTC from
   // this time structure (containing UTC).
   void UTCExplode(Exploded* exploded) const {
     return Explode(false, exploded);
   }
@@ -329,60 +329,60 @@ class Time {
   // Explodes the given time to either local time |is_local = true| or UTC
   // |is_local = false|.
   void Explode(bool is_local, Exploded* exploded) const;
 
   // Unexplodes a given time assuming the source is either local time
   // |is_local = true| or UTC |is_local = false|.
   static Time FromExploded(bool is_local, const Exploded& exploded);
 
-  Time(int64 us) : us_(us) {
+  Time(int64_t us) : us_(us) {
   }
 
   // The representation of Jan 1, 1970 UTC in microseconds since the
   // platform-dependent epoch.
-  static const int64 kTimeTToMicrosecondsOffset;
+  static const int64_t kTimeTToMicrosecondsOffset;
 
   // Time in microseconds in UTC.
-  int64 us_;
+  int64_t us_;
 };
 
 inline Time TimeDelta::operator+(Time t) const {
   return Time(t.us_ + delta_);
 }
 
 // Inline the TimeDelta factory methods, for fast TimeDelta construction.
 
 // static
-inline TimeDelta TimeDelta::FromDays(int64 days) {
+inline TimeDelta TimeDelta::FromDays(int64_t days) {
   return TimeDelta(days * Time::kMicrosecondsPerDay);
 }
 
 // static
-inline TimeDelta TimeDelta::FromHours(int64 hours) {
+inline TimeDelta TimeDelta::FromHours(int64_t hours) {
   return TimeDelta(hours * Time::kMicrosecondsPerHour);
 }
 
 // static
-inline TimeDelta TimeDelta::FromMinutes(int64 minutes) {
+inline TimeDelta TimeDelta::FromMinutes(int64_t minutes) {
   return TimeDelta(minutes * Time::kMicrosecondsPerMinute);
 }
 
 // static
-inline TimeDelta TimeDelta::FromSeconds(int64 secs) {
+inline TimeDelta TimeDelta::FromSeconds(int64_t secs) {
   return TimeDelta(secs * Time::kMicrosecondsPerSecond);
 }
 
 // static
-inline TimeDelta TimeDelta::FromMilliseconds(int64 ms) {
+inline TimeDelta TimeDelta::FromMilliseconds(int64_t ms) {
   return TimeDelta(ms * Time::kMicrosecondsPerMillisecond);
 }
 
 // static
-inline TimeDelta TimeDelta::FromMicroseconds(int64 us) {
+inline TimeDelta TimeDelta::FromMicroseconds(int64_t us) {
   return TimeDelta(us);
 }
 
 // TimeTicks ------------------------------------------------------------------
 
 class TimeTicks {
  public:
   TimeTicks() : ticks_(0) {
@@ -400,17 +400,17 @@ class TimeTicks {
   static TimeTicks HighResNow();
 
   // Returns true if this object has not been initialized.
   bool is_null() const {
     return ticks_ == 0;
   }
 
   // Returns the internal numeric value of the TimeTicks object.
-  int64 ToInternalValue() const {
+  int64_t ToInternalValue() const {
     return ticks_;
   }
 
   TimeTicks& operator=(TimeTicks other) {
     ticks_ = other.ticks_;
     return *this;
   }
 
@@ -458,21 +458,21 @@ class TimeTicks {
   }
 
  protected:
   friend class TimeDelta;
   friend class PageLoadTrackerUnitTest;
 
   // Please use Now() to create a new object. This is for internal use
   // and testing. Ticks is in microseconds.
-  explicit TimeTicks(int64 ticks) : ticks_(ticks) {
+  explicit TimeTicks(int64_t ticks) : ticks_(ticks) {
   }
 
   // Tick count in microseconds.
-  int64 ticks_;
+  int64_t ticks_;
 
 #if defined(OS_WIN)
   typedef DWORD (*TickFunctionType)(void);
   static TickFunctionType SetMockTickFunction(TickFunctionType ticker);
 #endif
 };
 
 inline TimeTicks TimeDelta::operator+(TimeTicks t) const {
--- a/ipc/chromium/src/base/time_mac.cc
+++ b/ipc/chromium/src/base/time_mac.cc
@@ -26,23 +26,23 @@ namespace base {
 
 // The internal representation of Time uses a 64-bit microsecond count
 // from 1970-01-01 00:00:00 UTC.  Core Foundation uses a double second count
 // since 2001-01-01 00:00:00 UTC.
 
 // Some functions in time.cc use time_t directly, so we provide a zero offset
 // for them.  The epoch is 1970-01-01 00:00:00 UTC.
 // static
-const int64 Time::kTimeTToMicrosecondsOffset = GG_INT64_C(0);
+const int64_t Time::kTimeTToMicrosecondsOffset = GG_INT64_C(0);
 
 // static
 Time Time::Now() {
   CFAbsoluteTime now =
       CFAbsoluteTimeGetCurrent() + kCFAbsoluteTimeIntervalSince1970;
-  return Time(static_cast<int64>(now * kMicrosecondsPerSecond));
+  return Time(static_cast<int64_t>(now * kMicrosecondsPerSecond));
 }
 
 // static
 Time Time::NowFromSystemTime() {
   // Just use Now() because Now() returns the system time.
   return Now();
 }
 
@@ -56,17 +56,17 @@ Time Time::FromExploded(bool is_local, c
   date.day = exploded.day_of_month;
   date.month = exploded.month;
   date.year = exploded.year;
 
   scoped_cftyperef<CFTimeZoneRef>
       time_zone(is_local ? CFTimeZoneCopySystem() : NULL);
   CFAbsoluteTime seconds = CFGregorianDateGetAbsoluteTime(date, time_zone) +
       kCFAbsoluteTimeIntervalSince1970;
-  return Time(static_cast<int64>(seconds * kMicrosecondsPerSecond));
+  return Time(static_cast<int64_t>(seconds * kMicrosecondsPerSecond));
 }
 
 void Time::Explode(bool is_local, Exploded* exploded) const {
   CFAbsoluteTime seconds =
       (static_cast<double>(us_) / kMicrosecondsPerSecond) -
       kCFAbsoluteTimeIntervalSince1970;
 
   scoped_cftyperef<CFTimeZoneRef>
--- a/ipc/chromium/src/base/time_posix.cc
+++ b/ipc/chromium/src/base/time_posix.cc
@@ -28,17 +28,17 @@ namespace base {
 // standard routines in the case of timegm.  We need to use a Mach-specific
 // function for TimeTicks::Now() on Mac OS X.
 
 // Time -----------------------------------------------------------------------
 
 // Some functions in time.cc use time_t directly, so we provide a zero offset
 // for them.  The epoch is 1970-01-01 00:00:00 UTC.
 // static
-const int64 Time::kTimeTToMicrosecondsOffset = GG_INT64_C(0);
+const int64_t Time::kTimeTToMicrosecondsOffset = GG_INT64_C(0);
 
 // static
 Time Time::Now() {
   struct timeval tv;
   struct timezone tz = { 0, 0 };  // UTC
   if (gettimeofday(&tv, &tz) != 0) {
     DCHECK(0) << "Could not determine time of day";
   }
@@ -73,17 +73,17 @@ Time Time::FromExploded(bool is_local, c
     seconds = mktime(&timestruct);
 #else
   if (is_local)
     seconds = mktime(&timestruct);
   else
     seconds = timegm(&timestruct);
 #endif
 
-  int64 milliseconds;
+  int64_t milliseconds;
   // Handle overflow.  Clamping the range to what mktime and timegm might
   // return is the best that can be done here.  It's not ideal, but it's better
   // than failing here or ignoring the overflow case and treating each time
   // overflow as one second prior to the epoch.
   if (seconds == -1 &&
       (exploded.year < 1969 || exploded.year > 1970)) {
     // If exploded.year is 1969 or 1970, take -1 as correct, with the
     // time indicating 1 second prior to the epoch.  (1970 is allowed to handle
@@ -112,17 +112,17 @@ Time Time::FromExploded(bool is_local, c
   }
 
   return Time(milliseconds * kMicrosecondsPerMillisecond);
 }
 
 void Time::Explode(bool is_local, Exploded* exploded) const {
   // Time stores times with microsecond resolution, but Exploded only carries
   // millisecond resolution, so begin by being lossy.
-  int64 milliseconds = us_ / kMicrosecondsPerMillisecond;
+  int64_t milliseconds = us_ / kMicrosecondsPerMillisecond;
   time_t seconds = milliseconds / kMillisecondsPerSecond;
 
   struct tm timestruct;
   if (is_local)
     localtime_r(&seconds, &timestruct);
   else
     gmtime_r(&seconds, &timestruct);
 
@@ -172,18 +172,18 @@ TimeTicks TimeTicks::Now() {
 
   struct timespec ts;
   if (clock_gettime(CLOCK_MONOTONIC, &ts) != 0) {
     NOTREACHED() << "clock_gettime(CLOCK_MONOTONIC) failed.";
     return TimeTicks();
   }
 
   absolute_micro =
-      (static_cast<int64>(ts.tv_sec) * Time::kMicrosecondsPerSecond) +
-      (static_cast<int64>(ts.tv_nsec) / Time::kNanosecondsPerMicrosecond);
+      (static_cast<int64_t>(ts.tv_sec) * Time::kMicrosecondsPerSecond) +
+      (static_cast<int64_t>(ts.tv_nsec) / Time::kNanosecondsPerMicrosecond);
 
 #else  // _POSIX_MONOTONIC_CLOCK
 #error No usable tick clock function on this platform.
 #endif  // _POSIX_MONOTONIC_CLOCK
 
   return TimeTicks(absolute_micro);
 }
 
--- a/ipc/chromium/src/base/time_win.cc
+++ b/ipc/chromium/src/base/time_win.cc
@@ -50,59 +50,59 @@
 using base::Time;
 using base::TimeDelta;
 using base::TimeTicks;
 
 namespace {
 
 // From MSDN, FILETIME "Contains a 64-bit value representing the number of
 // 100-nanosecond intervals since January 1, 1601 (UTC)."
-int64 FileTimeToMicroseconds(const FILETIME& ft) {
+int64_t FileTimeToMicroseconds(const FILETIME& ft) {
   // Need to bit_cast to fix alignment, then divide by 10 to convert
   // 100-nanoseconds to milliseconds. This only works on little-endian
   // machines.
-  return bit_cast<int64, FILETIME>(ft) / 10;
+  return bit_cast<int64_t, FILETIME>(ft) / 10;
 }
 
-void MicrosecondsToFileTime(int64 us, FILETIME* ft) {
+void MicrosecondsToFileTime(int64_t us, FILETIME* ft) {
   DCHECK(us >= 0) << "Time is less than 0, negative values are not "
       "representable in FILETIME";
 
   // Multiply by 10 to convert milliseconds to 100-nanoseconds. Bit_cast will
   // handle alignment problems. This only works on little-endian machines.
-  *ft = bit_cast<FILETIME, int64>(us * 10);
+  *ft = bit_cast<FILETIME, int64_t>(us * 10);
 }
 
-int64 CurrentWallclockMicroseconds() {
+int64_t CurrentWallclockMicroseconds() {
   FILETIME ft;
   ::GetSystemTimeAsFileTime(&ft);
   return FileTimeToMicroseconds(ft);
 }
 
 // Time between resampling the un-granular clock for this API.  60 seconds.
 const int kMaxMillisecondsToAvoidDrift = 60 * Time::kMillisecondsPerSecond;
 
-int64 initial_time = 0;
+int64_t initial_time = 0;
 TimeTicks initial_ticks;
 
 void InitializeClock() {
   initial_ticks = TimeTicks::Now();
   initial_time = CurrentWallclockMicroseconds();
 }
 
 }  // namespace
 
 // Time -----------------------------------------------------------------------
 
 // The internal representation of Time uses FILETIME, whose epoch is 1601-01-01
 // 00:00:00 UTC.  ((1970-1601)*365+89)*24*60*60*1000*1000, where 89 is the
 // number of leap year days between 1601 and 1970: (1970-1601)/4 excluding
 // 1700, 1800, and 1900.
 // static
-const int64 Time::kTimeTToMicrosecondsOffset = GG_INT64_C(11644473600000000);
+const int64_t Time::kTimeTToMicrosecondsOffset = GG_INT64_C(11644473600000000);
 
 // static
 Time Time::Now() {
   if (initial_time == 0)
     InitializeClock();
 
   // We implement time using the high-resolution timers so that we can get
   // timeouts which are smaller than 10-15ms.  If we just used
@@ -303,17 +303,17 @@ class HighResNowSingleton {
     ticks_per_microsecond_ = 0.0;
   }
 
   TimeDelta Now() {
     // Our maximum tolerance for QPC drifting.
     const int kMaxTimeDrift = 50 * Time::kMicrosecondsPerMillisecond;
 
     if (IsUsingHighResClock()) {
-      int64 now = UnreliableNow();
+      int64_t now = UnreliableNow();
 
       // Verify that QPC does not seem to drift.
       DCHECK(now - ReliableNow() - skew_ < kMaxTimeDrift);
 
       return TimeDelta::FromMicroseconds(now);
     }
 
     // Just fallback to the slower clock.
@@ -328,31 +328,31 @@ class HighResNowSingleton {
       return;  // Broken, we don't guarantee this function works.
     ticks_per_microsecond_ = static_cast<float>(ticks_per_sec.QuadPart) /
       static_cast<float>(Time::kMicrosecondsPerSecond);
 
     skew_ = UnreliableNow() - ReliableNow();
   }
 
   // Get the number of microseconds since boot in a reliable fashion
-  int64 UnreliableNow() {
+  int64_t UnreliableNow() {
     LARGE_INTEGER now;
     QueryPerformanceCounter(&now);
-    return static_cast<int64>(now.QuadPart / ticks_per_microsecond_);
+    return static_cast<int64_t>(now.QuadPart / ticks_per_microsecond_);
   }
 
   // Get the number of microseconds since boot in a reliable fashion
-  int64 ReliableNow() {
+  int64_t ReliableNow() {
     return Singleton<NowSingleton>::get()->Now().InMicroseconds();
   }
 
   // Cached clock frequency -> microseconds. This assumes that the clock
   // frequency is faster than one microsecond (which is 1MHz, should be OK).
   float ticks_per_microsecond_;  // 0 indicates QPF failed and we're broken.
-  int64 skew_;  // Skew between lo-res and hi-res clocks (for debugging).
+  int64_t skew_;  // Skew between lo-res and hi-res clocks (for debugging).
 
   DISALLOW_COPY_AND_ASSIGN(HighResNowSingleton);
 };
 
 }  // namespace
 
 // static
 TimeTicks::TickFunctionType TimeTicks::SetMockTickFunction(
--- a/ipc/chromium/src/base/time_win_unittest.cc
+++ b/ipc/chromium/src/base/time_win_unittest.cc
@@ -36,24 +36,24 @@ class MockTimeTicks : public TimeTicks {
 };
 
 volatile LONG MockTimeTicks::ticker_;
 MockTimeTicks::TickFunctionType MockTimeTicks::old_tick_function_;
 
 HANDLE g_rollover_test_start;
 
 unsigned __stdcall RolloverTestThreadMain(void* param) {
-  int64 counter = reinterpret_cast<int64>(param);
+  int64_t counter = reinterpret_cast<int64_t>(param);
   DWORD rv = WaitForSingleObject(g_rollover_test_start, INFINITE);
   EXPECT_EQ(rv, WAIT_OBJECT_0);
 
   TimeTicks last = TimeTicks::Now();
   for (int index = 0; index < counter; index++) {
     TimeTicks now = TimeTicks::Now();
-    int64 milliseconds = (now - last).InMilliseconds();
+    int64_t milliseconds = (now - last).InMilliseconds();
     // This is a tight loop; we could have looped faster than our
     // measurements, so the time might be 0 millis.
     EXPECT_GE(milliseconds, 0);
     EXPECT_LT(milliseconds, 250);
     last = now;
   }
   return 0;
 }
@@ -66,18 +66,18 @@ TEST(TimeTicks, WinRollover) {
   // Basic test algorithm:
   //   1) Set clock to rollover - N
   //   2) Create N threads
   //   3) Start the threads
   //   4) Each thread loops through TimeTicks() N times
   //   5) Each thread verifies integrity of result.
 
   const int kThreads = 8;
-  // Use int64 so we can cast into a void* without a compiler warning.
-  const int64 kChecks = 10;
+  // Use int64_t so we can cast into a void* without a compiler warning.
+  const int64_t kChecks = 10;
 
   // It takes a lot of iterations to reproduce the bug!
   // (See bug 1081395)
   for (int loop = 0; loop < 4096; loop++) {
     // Setup
     MockTimeTicks::InstallTicker();
     g_rollover_test_start = CreateEvent(0, TRUE, FALSE, 0);
     HANDLE threads[kThreads];
@@ -107,17 +107,17 @@ TEST(TimeTicks, WinRollover) {
   }
 }
 
 TEST(TimeTicks, SubMillisecondTimers) {
   // Loop for a bit getting timers quickly.  We want to
   // see at least one case where we get a new sample in
   // less than one millisecond.
   bool saw_submillisecond_timer = false;
-  int64 min_timer = 1000;
+  int64_t min_timer = 1000;
   TimeTicks last_time = TimeTicks::HighResNow();
   for (int index = 0; index < 1000; index++) {
     TimeTicks now = TimeTicks::HighResNow();
     TimeDelta delta = now - last_time;
     if (delta.InMicroseconds() > 0 &&
         delta.InMicroseconds() < 1000) {
       if (min_timer > delta.InMicroseconds())
         min_timer = delta.InMicroseconds();
--- a/ipc/chromium/src/base/trace_event.cc
+++ b/ipc/chromium/src/base/trace_event.cc
@@ -123,17 +123,17 @@ void TraceLog::Trace(const std::string& 
     return;
 
 #ifdef USE_UNRELIABLE_NOW
   TimeTicks tick = TimeTicks::HighResNow();
 #else
   TimeTicks tick = TimeTicks::Now();
 #endif
   TimeDelta delta = tick - trace_start_time_;
-  int64 usec = delta.InMicroseconds();
+  int64_t usec = delta.InMicroseconds();
   std::string msg =
     StringPrintf("{'pid':'0x%lx', 'tid':'0x%lx', 'type':'%s', "
                  "'name':'%s', 'id':'0x%lx', 'extra':'%s', 'file':'%s', "
                  "'line_number':'%d', 'usec_begin': %I64d},\n",
                  base::GetCurrentProcId(),
                  PlatformThread::CurrentId(),
                  kEventTypeNames[type],
                  name.c_str(),
--- a/ipc/chromium/src/base/tracked_objects.cc
+++ b/ipc/chromium/src/base/tracked_objects.cc
@@ -17,17 +17,17 @@ namespace tracked_objects {
 TLSSlot ThreadData::tls_index_(base::LINKER_INITIALIZED);
 
 //------------------------------------------------------------------------------
 // Death data tallies durations when a death takes place.
 
 void DeathData::RecordDeath(const TimeDelta& duration) {
   ++count_;
   life_duration_ += duration;
-  int64 milliseconds = duration.InMilliseconds();
+  int64_t milliseconds = duration.InMilliseconds();
   square_duration_ += milliseconds * milliseconds;
 }
 
 int DeathData::AverageMsDuration() const {
   return static_cast<int>(life_duration_.InMilliseconds() / count_);
 }
 
 double DeathData::StandardDeviation() const {
--- a/ipc/chromium/src/base/tracked_objects.h
+++ b/ipc/chromium/src/base/tracked_objects.h
@@ -80,32 +80,32 @@ class DeathData {
   // a corrosponding death.
   explicit DeathData(int count) : count_(count), square_duration_(0) {}
 
   void RecordDeath(const base::TimeDelta& duration);
 
   // Metrics accessors.
   int count() const { return count_; }
   base::TimeDelta life_duration() const { return life_duration_; }
-  int64 square_duration() const { return square_duration_; }
+  int64_t square_duration() const { return square_duration_; }
   int AverageMsDuration() const;
   double StandardDeviation() const;
 
   // Accumulate metrics from other into this.
   void AddDeathData(const DeathData& other);
 
   // Simple print of internal state.
   void Write(std::string* output) const;
 
   void Clear();
 
  private:
   int count_;                // Number of destructions.
   base::TimeDelta life_duration_;    // Sum of all lifetime durations.
-  int64 square_duration_;  // Sum of squares in milliseconds.
+  int64_t square_duration_;  // Sum of squares in milliseconds.
 };
 
 //------------------------------------------------------------------------------
 // A temporary collection of data that can be sorted and summarized.  It is
 // gathered (carefully) from many threads.  Instances are held in arrays and
 // processed, filtered, and rendered.
 // The source of this data was collected on many threads, and is asynchronously
 // changing.  The data in this instance is not asynchronously changing.
@@ -124,17 +124,17 @@ class Snapshot {
   const Location location() const { return birth_->location(); }
   const BirthOnThread& birth() const { return *birth_; }
   const ThreadData* death_thread() const {return death_thread_; }
   const DeathData& death_data() const { return death_data_; }
   const std::string DeathThreadName() const;
 
   int count() const { return death_data_.count(); }
   base::TimeDelta life_duration() const { return death_data_.life_duration(); }
-  int64 square_duration() const { return death_data_.square_duration(); }
+  int64_t square_duration() const { return death_data_.square_duration(); }
   int AverageMsDuration() const { return death_data_.AverageMsDuration(); }
 
   void Write(std::string* output) const;
 
   void Add(const Snapshot& other);
 
  private:
   const BirthOnThread* birth_;  // Includes Location and birth_thread.
--- a/ipc/chromium/src/base/version.cc
+++ b/ipc/chromium/src/base/version.cc
@@ -23,17 +23,17 @@ Version* Version::GetVersionFromString(c
   return NULL;
 }
 
 bool Version::Equals(const Version& that) const {
   return CompareTo(that) == 0;
 }
 
 int Version::CompareTo(const Version& other) const {
-  std::vector<uint16> other_components = other.components();
+  std::vector<uint16_t> other_components = other.components();
   size_t count = std::min(components_.size(), other_components.size());
   for (size_t i = 0; i < count; ++i) {
     if (components_[i] > other_components[i])
       return 1;
     if (components_[i] < other_components[i])
       return -1;
   }
   if (components_.size() > other_components.size()) {
@@ -64,19 +64,19 @@ bool Version::InitFromString(const std::
   SplitString(version_str, '.', &numbers);
   for (std::vector<std::string>::iterator i = numbers.begin();
        i != numbers.end(); ++i) {
     int num;
     if (!StringToInt(*i, &num))
       return false;
     if (num < 0)
       return false;
-    const uint16 max = 0xFFFF;
+    const uint16_t max = 0xFFFF;
     if (num > max)
       return false;
     // This throws out things like +3, or 032.
     if (IntToString(num) != *i)
       return false;
-    uint16 component = static_cast<uint16>(num);
+    uint16_t component = static_cast<uint16_t>(num);
     components_.push_back(component);
   }
   return true;
 }
--- a/ipc/chromium/src/base/version.h
+++ b/ipc/chromium/src/base/version.h
@@ -7,34 +7,34 @@
 
 #include <string>
 #include <vector>
 
 #include "base/basictypes.h"
 
 class Version {
 public:
-  // The version string must be made up of 1 or more uint16's separated
+  // The version string must be made up of 1 or more uint16_t's separated
   // by '.'. Returns NULL if string is not in this format.
   // Caller is responsible for freeing the Version object once done.
   static Version* GetVersionFromString(const std::wstring& version_str);
   static Version* GetVersionFromString(const std::string& version_str);
 
   ~Version() {}
 
   bool Equals(const Version& other) const;
 
   // Returns -1, 0, 1 for <, ==, >.
   int CompareTo(const Version& other) const;
 
   // Return the string representation of this version.
   const std::string GetString() const;
 
-  const std::vector<uint16>& components() const { return components_; }
+  const std::vector<uint16_t>& components() const { return components_; }
 
 private:
   Version() {}
   bool InitFromString(const std::string& version_str);
 
-  std::vector<uint16> components_;
+  std::vector<uint16_t> components_;
 };
 
 #endif  // BASE_VERSION_H_
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.cc
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.cc
@@ -48,37 +48,37 @@ void AppCacheContextImpl::UnInitializeCo
     sender_->Send(new AppCacheMsg_ContextDestroyed(context_id_));
     all_contexts.Remove(context_id_);
     context_id_ = kNoAppCacheContextId;
   }
 }
 
 void AppCacheContextImpl::SelectAppCacheWithoutManifest(
                               const GURL &document_url,
-                              int64 cache_document_was_loaded_from) {
+                              int64_t cache_document_was_loaded_from) {
   DCHECK(context_id_ != kNoAppCacheContextId);
   app_cache_id_ = kUnknownAppCacheId;  // unknown until we get a response
   sender_->Send(new AppCacheMsg_SelectAppCache(
                          context_id_, ++pending_select_request_id_,
                          document_url, cache_document_was_loaded_from,
                          GURL::EmptyGURL()));
 }
 
 void AppCacheContextImpl::SelectAppCacheWithManifest(
                               const GURL &document_url,
-                              int64 cache_document_was_loaded_from,
+                              int64_t cache_document_was_loaded_from,
                               const GURL &manifest_url) {
   DCHECK(context_id_ != kNoAppCacheContextId);
   app_cache_id_ = kUnknownAppCacheId;  // unknown until we get a response
   sender_->Send(new AppCacheMsg_SelectAppCache(
                          context_id_, ++pending_select_request_id_,
                          document_url, cache_document_was_loaded_from,
                          manifest_url));
 }
 
 void AppCacheContextImpl::OnAppCacheSelected(int select_request_id,
-                                             int64 app_cache_id) {
+                                             int64_t app_cache_id) {
   if (select_request_id == pending_select_request_id_) {
     DCHECK(app_cache_id_ == kUnknownAppCacheId);
     DCHECK(app_cache_id != kUnknownAppCacheId);
     app_cache_id_ = app_cache_id;
   }
 }
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.h
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_context_impl.h
@@ -15,34 +15,34 @@ class AppCacheContextImpl : public WebAp
   // Returns the context having given id or NULL if there is no such context.
   static AppCacheContextImpl* FromContextId(int id);
 
   AppCacheContextImpl(IPC::Message::Sender* sender);
   virtual ~AppCacheContextImpl();
 
   // WebAppCacheContext implementation
   virtual int GetContextID() { return context_id_; }
-  virtual int64 GetAppCacheID() { return app_cache_id_; }
+  virtual int64_t GetAppCacheID() { return app_cache_id_; }
   virtual void Initialize(WebAppCacheContext::ContextType context_type,
                           WebAppCacheContext* opt_parent);
   virtual void SelectAppCacheWithoutManifest(
                                      const GURL& document_url,
-                                     int64 cache_document_was_loaded_from);
+                                     int64_t cache_document_was_loaded_from);
   virtual void SelectAppCacheWithManifest(
                                      const GURL& document_url,
-                                     int64 cache_document_was_loaded_from,
+                                     int64_t cache_document_was_loaded_from,
                                      const GURL& manifest_url);
 
   // Called by AppCacheDispatcher when the browser has selected an appcache.
-  void OnAppCacheSelected(int select_request_id, int64 app_cache_id);
+  void OnAppCacheSelected(int select_request_id, int64_t app_cache_id);
 
  private:
   void UnInitializeContext();
 
   int context_id_;
-  int64 app_cache_id_;
+  int64_t app_cache_id_;
   int pending_select_request_id_;
   IPC::Message::Sender* sender_;
 
   static IDMap<AppCacheContextImpl> all_contexts;
 };
 
 #endif  // CHROME_COMMON_APP_CACHE_APP_CACHE_CONTEXT_IMPL_H_
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.cc
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.cc
@@ -13,14 +13,14 @@ bool AppCacheDispatcher::OnMessageReceiv
     IPC_MESSAGE_HANDLER(AppCacheMsg_AppCacheSelected, OnAppCacheSelected)
     IPC_MESSAGE_UNHANDLED(handled = false)
   IPC_END_MESSAGE_MAP()
   return handled;
 }
 
 void AppCacheDispatcher::OnAppCacheSelected(int context_id,
                                             int select_request_id,
-                                            int64 app_cache_id) {
+                                            int64_t app_cache_id) {
   AppCacheContextImpl *context = AppCacheContextImpl::FromContextId(context_id);
   if (context) {
     context->OnAppCacheSelected(select_request_id, app_cache_id);
   }
 }
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.h
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher.h
@@ -15,12 +15,12 @@
 class AppCacheDispatcher {
  public:
   bool OnMessageReceived(const IPC::Message& msg);
 
  private:
   // AppCacheContextImpl related messages
   void OnAppCacheSelected(int context_id,
                           int select_request_id,
-                          int64 app_cache_id);
+                          int64_t app_cache_id);
 };
 
 #endif  // CHROME_COMMON_APP_CACHE_APP_CACHE_DISPATCHER_H_
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.cc
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.cc
@@ -46,15 +46,15 @@ void AppCacheDispatcherHost::OnContextDe
   // TODO(michaeln): implement me, plumb to request_context->app_cache_service
   DCHECK(context_id != WebAppCacheContext::kNoAppCacheContextId);
 }
 
 void AppCacheDispatcherHost::OnSelectAppCache(
                                 int context_id,
                                 int select_request_id,
                                 const GURL& document_url,
-                                int64 cache_document_was_loaded_from,
+                                int64_t cache_document_was_loaded_from,
                                 const GURL& opt_manifest_url) {
   // TODO(michaeln): implement me, plumb to request_context->app_cache_service
   DCHECK(context_id != WebAppCacheContext::kNoAppCacheContextId);
   Send(new AppCacheMsg_AppCacheSelected(context_id, select_request_id,
                                         WebAppCacheContext::kNoAppCacheId));
 }
--- a/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.h
+++ b/ipc/chromium/src/chrome/common/app_cache/app_cache_dispatcher_host.h
@@ -25,17 +25,17 @@ class AppCacheDispatcherHost {
  private:
   // AppCacheContextImpl related messages
   void OnContextCreated(WebAppCacheContext::ContextType context_type,
                         int context_id, int opt_parent_id);
   void OnContextDestroyed(int context_id);
   void OnSelectAppCache(int context_id,
                         int select_request_id,
                         const GURL& document_url,
-                        int64 cache_document_was_loaded_from,
+                        int64_t cache_document_was_loaded_from,
                         const GURL& opt_manifest_url);
 
   bool Send(IPC::Message* msg) {
     return sender_->Send(msg);
   }
 
   IPC::Message::Sender* sender_;
 };
--- a/ipc/chromium/src/chrome/common/child_process_host.cc
+++ b/ipc/chromium/src/chrome/common/child_process_host.cc
@@ -162,17 +162,17 @@ void ChildProcessHost::ListenerHook::OnM
     base::KillProcess(host_->handle(), ResultCodes::KILLED_BAD_MESSAGE, false);
 
 #ifdef IPC_MESSAGE_LOG_ENABLED
   if (logger->Enabled())
     logger->OnPostDispatchMessage(msg, host_->channel_id_);
 #endif
 }
 
-void ChildProcessHost::ListenerHook::OnChannelConnected(int32 peer_pid) {
+void ChildProcessHost::ListenerHook::OnChannelConnected(int32_t peer_pid) {
   host_->opening_channel_ = false;
   host_->OnChannelConnected(peer_pid);
 
   // Notify in the main loop of the connection.
   host_->Notify(NotificationType::CHILD_PROCESS_HOST_CONNECTED);
 }
 
 void ChildProcessHost::ListenerHook::OnChannelError() {
--- a/ipc/chromium/src/chrome/common/child_process_host.h
+++ b/ipc/chromium/src/chrome/common/child_process_host.h
@@ -65,17 +65,17 @@ class ChildProcessHost :
   // ChildProcessHost using this function.
   void SetHandle(base::ProcessHandle handle);
 
   // Notifies us that an instance has been created on this child process.
   void InstanceCreated();
 
   // IPC::Channel::Listener implementation:
   virtual void OnMessageReceived(const IPC::Message& msg) { }
-  virtual void OnChannelConnected(int32 peer_pid) { }
+  virtual void OnChannelConnected(int32_t peer_pid) { }
   virtual void OnChannelError() { }
 
   bool opening_channel() { return opening_channel_; }
   const std::wstring& channel_id() { return channel_id_; }
 
   base::WaitableEvent* GetProcessEvent() { return process_event_.get(); }
 
   const IPC::Channel& channel() const { return *channel_; }
@@ -92,17 +92,17 @@ class ChildProcessHost :
  private:
   // By using an internal class as the IPC::Channel::Listener, we can intercept
   // OnMessageReceived/OnChannelConnected and do our own processing before
   // calling the subclass' implementation.
   class ListenerHook : public IPC::Channel::Listener {
    public:
     ListenerHook(ChildProcessHost* host);
     virtual void OnMessageReceived(const IPC::Message& msg);
-    virtual void OnChannelConnected(int32 peer_pid);
+    virtual void OnChannelConnected(int32_t peer_pid);
     virtual void OnChannelError();
     virtual void GetQueuedMessages(std::queue<IPC::Message>& queue);
    private:
     ChildProcessHost* host_;
   };
 
   ListenerHook listener_;
 
--- a/ipc/chromium/src/chrome/common/child_thread.cc
+++ b/ipc/chromium/src/chrome/common/child_thread.cc
@@ -38,23 +38,23 @@ bool ChildThread::Send(IPC::Message* msg
   if (!channel_.get()) {
     delete msg;
     return false;
   }
 
   return channel_->Send(msg);
 }
 
-void ChildThread::AddRoute(int32 routing_id, IPC::Channel::Listener* listener) {
+void ChildThread::AddRoute(int32_t routing_id, IPC::Channel::Listener* listener) {
   DCHECK(MessageLoop::current() == message_loop());
 
   router_.AddRoute(routing_id, listener);
 }
 
-void ChildThread::RemoveRoute(int32 routing_id) {
+void ChildThread::RemoveRoute(int32_t routing_id) {
   DCHECK(MessageLoop::current() == message_loop());
 
   router_.RemoveRoute(routing_id);
 }
 
 void ChildThread::OnMessageReceived(const IPC::Message& msg) {
   if (msg.routing_id() == MSG_ROUTING_CONTROL) {
     OnControlMessageReceived(msg);
--- a/ipc/chromium/src/chrome/common/child_thread.h
+++ b/ipc/chromium/src/chrome/common/child_thread.h
@@ -19,18 +19,18 @@ class ChildThread : public IPC::Channel:
   // Creates the thread.
   ChildThread(Thread::Options options);
   virtual ~ChildThread();
 
   // IPC::Message::Sender implementation:
   virtual bool Send(IPC::Message* msg);
 
   // See documentation on MessageRouter for AddRoute and RemoveRoute
-  void AddRoute(int32 routing_id, IPC::Channel::Listener* listener);
-  void RemoveRoute(int32 routing_id);
+  void AddRoute(int32_t routing_id, IPC::Channel::Listener* listener);
+  void RemoveRoute(int32_t routing_id);
 
   MessageLoop* owner_loop() { return owner_loop_; }
 
  protected:
   friend class ChildProcess;
 
   // Starts the thread.
   bool Run();
--- a/ipc/chromium/src/chrome/common/chrome_plugin_api.h
+++ b/ipc/chromium/src/chrome/common/chrome_plugin_api.h
@@ -82,17 +82,17 @@ typedef struct _CPID_t {
 } CPID_t;
 typedef struct _CPID_t* CPID;
 
 // An identifier that encapsulates the browsing context needed by various APIs.
 // This includes information about what tab a request was made from, and what
 // profile is active.  Note that this ID is global to all processes, so it can
 // be passed from one process to another.  The value 0 is reserved for an
 // undefined context.
-typedef uint32 CPBrowsingContext;
+typedef uint32_t CPBrowsingContext;
 
 // Types of context info to query using CPB_GetBrowsingContextInfo.
 typedef enum {
   // The data directory for the profile associated with this context as a
   // pointer to a null-terminated string.  The plugin can save persistent data
   // to this directory.  The returned pointer should be freed using CPB_Free.
   CPBROWSINGCONTEXT_DATA_DIR_PTR = 0,
 
@@ -175,17 +175,17 @@ typedef CPError (STDCALL *CPB_HandleComm
 // the given schemes.  'schemes' is an array of strings containing the scheme
 // names the plugin wishes to handle; case is ignored.  If 'schemes' is NULL or
 // empty, request interception is disabled for this plugin.  Multiple calls to
 // this function will add to the existing set of enabled schemes. The browser
 // should call the plugin's CPP_ShouldInterceptRequestFunc for any network
 // requests it makes that match a given scheme.  The browser may choose not to
 // allow the plugin to intercept certain protocols.
 typedef void (STDCALL *CPB_EnableRequestInterceptFunc)(
-    CPID id, const char** schemes, uint32 num_schemes);
+    CPID id, const char** schemes, uint32_t num_schemes);
 
 // Asks the browser to create a request object for the given method/url.
 // Returns CPERR_SUCCESS and puts the new object into the 'request' field on
 // success, or an error code on failure.  The plugin must call CPR_EndRequest
 // to clean up the request object when it is done with it.
 typedef CPError (STDCALL *CPB_CreateRequestFunc)(
     CPID id, CPBrowsingContext context, const char* method, const char* url,
     CPRequest** request);
@@ -194,17 +194,17 @@ typedef CPError (STDCALL *CPB_CreateRequ
 // Sets 'cookies' to an allocated string containing the cookies as
 // semicolon-delimited "name=value" pairs on success, NULL on failure.
 // The memory should be freed using CPB_Free when done.
 typedef CPError (STDCALL *CPB_GetCookiesFunc)(
     CPID id, CPBrowsingContext context, const char* url, char** cookies);
 
 // Allocates memory for the given size using the browser's allocator.  Call
 // CPB_Free when done.
-typedef void* (STDCALL *CPB_AllocFunc)(uint32 size);
+typedef void* (STDCALL *CPB_AllocFunc)(uint32_t size);
 
 // Frees a pointer allocated by CPB_Alloc.
 typedef void (STDCALL *CPB_FreeFunc)(void* memory);
 
 
 // Sets a flag that influences when the plugin process created to host
 // the plugin is shutdown. Generally, the plugin process is terminated
 // when no more plugin instances exist, this is the default behavior.
@@ -239,17 +239,17 @@ typedef CPBrowsingContext (STDCALL *CPB_
     struct _NPP* npp);
 
 // Queries for some meta data associated with the given browsing context.  See
 // CPBrowsingContextInfoType for possible queries.  If buf_size is too small to
 // contain the entire data, the return value will indicate the size required.
 // Otherwise, the return value is a CPError or CPERR_SUCCESS.
 typedef int (STDCALL *CPB_GetBrowsingContextInfoFunc)(
     CPID id, CPBrowsingContext context, CPBrowsingContextInfoType type,
-    void* buf, uint32 buf_size);
+    void* buf, uint32_t buf_size);
 
 // Given an URL string, returns the string of command-line arguments that should
 // be passed to start the browser at the given URL.  'arguments' should be freed
 // using CPB_Free when done.
 typedef CPError (STDCALL *CPB_GetCommandLineArgumentsFunc)(
     CPID id, CPBrowsingContext context, const char* url, char** arguments);
 
 // Asks the browser to let the plugin handle the given UI command.  When the
@@ -283,17 +283,17 @@ typedef void (STDCALL *CPR_EndRequestFun
 // Plugins should avoid setting the following headers: User-Agent,
 // Content-Length.
 typedef void (STDCALL *CPR_SetExtraRequestHeadersFunc)(CPRequest* request,
                                                        const char* headers);
 
 // Sets the load flags for this request. 'flags' is a bitwise-OR of
 // CPRequestLoadFlags.  Must be called before CPRR_StartCompletedFunc.
 typedef void (STDCALL *CPR_SetRequestLoadFlagsFunc)(CPRequest* request,
-                                                    uint32 flags);
+                                                    uint32_t flags);
 
 // Appends binary data to the request body of a POST or PUT request.  The caller
 // should set the "Content-Type" header to the appropriate mime type using
 // CPR_SetExtraRequestHeadersFunc.  This can be called multiple times to append
 // a sequence of data segments to upload.  Must be called before
 // CPR_StartRequestFunc.
 typedef void (STDCALL *CPR_AppendDataToUploadFunc)(
     CPRequest* request, const char* bytes, int bytes_len);
@@ -303,33 +303,33 @@ typedef void (STDCALL *CPR_AppendDataToU
 // for 'length' and 'offset' to upload the entire file. 'offset'
 // indicates where the data to upload begins in the file. 'length' indicates
 // how much of the file to upload. A 'length' of zero is interpretted as to
 // end-of-file. If 'length' and 'offset' indicate a range beyond end of file,
 // the amount sent is clipped at eof.
 // See CPR_AppendDataToUploadFunc for additional usage information.
 // (added in v0.4)
 typedef CPError (STDCALL *CPR_AppendFileToUploadFunc)(
-    CPRequest* request, const char* filepath, uint64 offset, uint64 length);
+    CPRequest* request, const char* filepath, uint64_t offset, uint64_t length);
 
 // Queries for some response meta data.  See CPResponseInfoType for possible
 // queries.  If buf_size is too small to contain the entire data, the return
 // value will indicate the size required.  Otherwise, the return value is a
 // CPError or CPERR_SUCCESS.
 typedef int (STDCALL *CPR_GetResponseInfoFunc)(
     CPRequest* request, CPResponseInfoType type,
-    void* buf, uint32 buf_size);
+    void* buf, uint32_t buf_size);
 
 // Attempts to read a request's response data.  The number of bytes read is
 // returned; 0 indicates an EOF.  CPERR_IO_PENDING is returned if an
 // asynchronous operation was started, and CPRR_ReadCompletedFunc will be called
 // when it completes; 'buf' must be available until the operation completes.
 // Returns an error code on failure.
 typedef int (STDCALL *CPR_ReadFunc)(
-    CPRequest* request, void* buf, uint32 buf_size);
+    CPRequest* request, void* buf, uint32_t buf_size);
 
 //
 // Functions related to serving network requests.
 // Both the host and plugin will implement their own versions of these.
 //
 
 // Called upon a server-initiated redirect.  The request will still hold the
 // original URL, and 'new_url' will be the redirect destination.
@@ -349,45 +349,45 @@ typedef void (STDCALL *CPRR_StartComplet
 // destroyed after the call completes.  On failure, 'bytes_read' holds the error
 // code.
 typedef void (STDCALL *CPRR_ReadCompletedFunc)(CPRequest* request,
                                                int bytes_read);
 
 // Called as upload progress is being made for async POST requests.
 // (added in v0.5)
 typedef void (STDCALL *CPRR_UploadProgressFunc)(CPRequest* request,
-                                                uint64 position,
-                                                uint64 size);
+                                                uint64_t position,
+                                                uint64_t size);
 
 //
 // Functions to support the sending and receipt of messages between processes.
 //
 
 // Returns true if the plugin process is running
 typedef CPBool (STDCALL *CPB_IsPluginProcessRunningFunc)(CPID id);
 
 // Returns the type of the current process.
 typedef CPProcessType (STDCALL *CPB_GetProcessTypeFunc)(CPID id);
 
 // Asks the browser to send raw data to the other process hosting an instance of
 // this plugin. If needed, the plugin process will be started prior to sending
 // the message.
 typedef CPError (STDCALL *CPB_SendMessageFunc)(CPID id,
                                                const void *data,
-                                               uint32 data_len);
+                                               uint32_t data_len);
 
 // Asks the browser to send raw data to the other process hosting an instance of
 // this plugin. This function only works from the plugin or renderer process.
 // This function blocks until the message is processed.  The memory should be
 // freed using CPB_Free when done.
 typedef CPError (STDCALL *CPB_SendSyncMessageFunc)(CPID id,
                                                    const void *data,
-                                                   uint32 data_len,
+                                                   uint32_t data_len,
                                                    void **retval,
-                                                   uint32 *retval_len);
+                                                   uint32_t *retval_len);
 
 // This function asynchronously calls the provided function on the plugin
 // thread.  user_data is passed as the argument to the function.
 typedef CPError (STDCALL *CPB_PluginThreadAsyncCallFunc)(CPID id,
                                                          void (*func)(void *),
                                                          void *user_data);
 
 // This function creates an open file dialog.  The process is granted access
@@ -396,82 +396,82 @@ typedef CPError (STDCALL *CPB_PluginThre
 typedef CPError (STDCALL *CPB_OpenFileDialogFunc)(CPID id,
                                                   CPBrowsingContext context,
                                                   bool multiple_files,
                                                   const char *title,
                                                   const char *filter,
                                                   void *user_data);
 
 // Informs the plugin of raw data having been sent from another process.
-typedef void (STDCALL *CPP_OnMessageFunc)(void *data, uint32 data_len);
+typedef void (STDCALL *CPP_OnMessageFunc)(void *data, uint32_t data_len);
 
 // Informs the plugin of raw data having been sent from another process.
-typedef void (STDCALL *CPP_OnSyncMessageFunc)(void *data, uint32 data_len,
+typedef void (STDCALL *CPP_OnSyncMessageFunc)(void *data, uint32_t data_len,
                                               void **retval,
-                                              uint32 *retval_len);
+                                              uint32_t *retval_len);
 
 // Informs the plugin that the file dialog has completed, and contains the
 // results.
 typedef void (STDCALL *CPP_OnFileDialogResultFunc)(void *data,
                                                    const char **files,
-                                                   uint32 files_len);
+                                                   uint32_t files_len);
 
 // Function table for issuing requests using via the other side's network stack.
 // For the plugin, this functions deal with issuing requests through the
 // browser.  For the browser, these functions deal with allowing the plugin to
 // intercept requests.
 typedef struct _CPRequestFuncs {
-  uint16 size;
+  uint16_t size;
   CPR_SetExtraRequestHeadersFunc set_extra_request_headers;
   CPR_SetRequestLoadFlagsFunc set_request_load_flags;
   CPR_AppendDataToUploadFunc append_data_to_upload;
   CPR_StartRequestFunc start_request;
   CPR_EndRequestFunc end_request;
   CPR_GetResponseInfoFunc get_response_info;
   CPR_ReadFunc read;
   CPR_AppendFileToUploadFunc append_file_to_upload;
 } CPRequestFuncs;
 
 // Function table for handling requests issued by the other side.  For the
 // plugin, these deal with serving requests that the plugin has intercepted. For
 // the browser, these deal with serving requests that the plugin has issued
 // through us.
 typedef struct _CPResponseFuncs {
-  uint16 size;
+  uint16_t size;
   CPRR_ReceivedRedirectFunc received_redirect;
   CPRR_StartCompletedFunc start_completed;
   CPRR_ReadCompletedFunc read_completed;
   CPRR_UploadProgressFunc upload_progress;
 } CPResponseFuncs;
 
 // Function table of CPP functions (functions provided by plugin to host). This
 // structure is filled in by the plugin in the CP_Initialize call, except for
 // the 'size' field, which is set by the browser.  The version fields should be
 // set to those that the plugin was compiled using.
 typedef struct _CPPluginFuncs {
-  uint16 size;
-  uint16 version;
+  uint16_t size;
+  uint16_t version;
   CPRequestFuncs* request_funcs;
   CPResponseFuncs* response_funcs;
   CPP_ShutdownFunc shutdown;
   CPP_ShouldInterceptRequestFunc should_intercept_request;
   CPP_OnMessageFunc on_message;
   CPP_HtmlDialogClosedFunc html_dialog_closed;
   CPP_HandleCommandFunc handle_command;
   CPP_OnSyncMessageFunc on_sync_message;
   CPP_OnFileDialogResultFunc on_file_dialog_result;
 } CPPluginFuncs;
 
 // Function table CPB functions (functions provided by host to plugin).
 // This structure is filled in by the browser and provided to the plugin.  The
 // plugin will likely want to save a copy of this structure to make calls
 // back to the browser.
 typedef struct _CPBrowserFuncs {
-  uint16 size;
-  uint16 version;
+  uint16_t size;
+  uint16_t version;
   CPRequestFuncs* request_funcs;
   CPResponseFuncs* response_funcs;
   CPB_EnableRequestInterceptFunc enable_request_intercept;
   CPB_CreateRequestFunc create_request;
   CPB_GetCookiesFunc get_cookies;
   CPB_AllocFunc alloc;
   CPB_FreeFunc free;
   CPB_SetKeepProcessAliveFunc set_keep_process_alive;
@@ -501,17 +501,17 @@ typedef struct _CPBrowserFuncs {
 // lowest version of the interface supported by the browser, 'max_version' is
 // the highest supported version. The plugin can specify which version within
 // the range should be used. This version will be reflected in the version field
 // of the CPBrowserFuncs struct passed to CP_Initialize. If this function
 // returns an error code, CP_Initialize will not be called. If function is not
 // exported by the chrome plugin module, CP_Initiailize will be called with
 // a version of the host's choosing.
 typedef CPError (STDCALL *CP_VersionNegotiateFunc)(
-  uint16 min_version, uint16 max_version, uint16 *selected_version);
+  uint16_t min_version, uint16_t max_version, uint16_t *selected_version);
 
 // 'bfuncs' are the browser functions provided to the plugin. 'id' is the
 // plugin identifier that the plugin should use when calling browser functions.
 // The plugin should initialize 'pfuncs' with pointers to its own functions,
 // or return an error code.
 // All functions and entry points should be called on the same thread.  The
 // plugin should not attempt to call a browser function from a thread other
 // than the one CP_InitializeFunc is called from.
--- a/ipc/chromium/src/chrome/common/chrome_plugin_lib.cc
+++ b/ipc/chromium/src/chrome/common/chrome_plugin_lib.cc
@@ -209,17 +209,17 @@ bool ChromePluginLib::CP_Initialize(cons
                "): initialized=" << initialized_;
   if (initialized_)
     return true;
 
   if (!Load())
     return false;
 
   if (CP_VersionNegotiate_) {
-    uint16 selected_version = 0;
+    uint16_t selected_version = 0;
     CPError rv = CP_VersionNegotiate_(CP_VERSION, CP_VERSION,
                                       &selected_version);
     if ( (rv != CPERR_SUCCESS) || (selected_version != CP_VERSION))
       return false;
   }
 
   plugin_funcs_.size = sizeof(plugin_funcs_);
   CPError rv = CP_Initialize_(cpid(), bfuncs, &plugin_funcs_);
--- a/ipc/chromium/src/chrome/common/chrome_plugin_util.cc
+++ b/ipc/chromium/src/chrome/common/chrome_plugin_util.cc
@@ -74,18 +74,18 @@ void PluginHelper::Observe(NotificationT
 
   delete this;
 }
 
 //
 // PluginResponseUtils
 //
 
-uint32 PluginResponseUtils::CPLoadFlagsToNetFlags(uint32 flags) {
-  uint32 net_flags = 0;
+uint32_t PluginResponseUtils::CPLoadFlagsToNetFlags(uint32_t flags) {
+  uint32_t net_flags = 0;
 #define HANDLE_FLAG(name) \
   if (flags & CPREQUEST##name) \
   net_flags |= net::name
 
   HANDLE_FLAG(LOAD_VALIDATE_CACHE);
   HANDLE_FLAG(LOAD_BYPASS_CACHE);
   HANDLE_FLAG(LOAD_PREFERRING_CACHE);
   HANDLE_FLAG(LOAD_ONLY_FROM_CACHE);
@@ -151,15 +151,15 @@ CPError CPB_GetCommandLineArgumentsCommo
 
   return CPERR_SUCCESS;
 }
 
 //
 // Host functions shared by browser and plugin processes
 //
 
-void* STDCALL CPB_Alloc(uint32 size) {
+void* STDCALL CPB_Alloc(uint32_t size) {
   return malloc(size);
 }
 
 void STDCALL CPB_Free(void* memory) {
   free(memory);
 }
--- a/ipc/chromium/src/chrome/common/chrome_plugin_util.h
+++ b/ipc/chromium/src/chrome/common/chrome_plugin_util.h
@@ -56,30 +56,30 @@ class PluginHelper : public Notification
   DISALLOW_COPY_AND_ASSIGN(PluginHelper);
 };
 
 // A class of utility functions for dealing with request responses.
 class PluginResponseUtils {
 public:
   // Helper to convert request load flags from the plugin API to the net API
   // versions.
-  static uint32 CPLoadFlagsToNetFlags(uint32 flags);
+  static uint32_t CPLoadFlagsToNetFlags(uint32_t flags);
 
   // Common implementation of a CPR_GetResponseInfo call.
   static int GetResponseInfo(
       const net::HttpResponseHeaders* response_headers,
       CPResponseInfoType type, void* buf, size_t buf_size);
 };
 
 // Helper to allocate a string using the given CPB_Alloc function.
 inline char* CPB_StringDup(CPB_AllocFunc alloc, const std::string& str) {
-  char* cstr = static_cast<char*>(alloc(static_cast<uint32>(str.length() + 1)));
+  char* cstr = static_cast<char*>(alloc(static_cast<uint32_t>(str.length() + 1)));
   memcpy(cstr, str.c_str(), str.length() + 1);  // Include null terminator.
   return cstr;
 }
 
 CPError CPB_GetCommandLineArgumentsCommon(const char* url,
                                           std::string* arguments);
 
-void* STDCALL CPB_Alloc(uint32 size);
+void* STDCALL CPB_Alloc(uint32_t size);
 void STDCALL CPB_Free(void* memory);
 
 #endif  // CHROME_COMMON_CHROME_PLUGIN_UTIL_H_
--- a/ipc/chromium/src/chrome/common/filter_policy.h
+++ b/ipc/chromium/src/chrome/common/filter_policy.h
@@ -23,21 +23,21 @@ class FilterPolicy {
     //               change it to something more suggestive of what this
     //               actually does.
     FILTER_ALL_EXCEPT_IMAGES,
 
     // Block all types of resources.
     FILTER_ALL
   };
 
-  static bool ValidType(int32 type) {
+  static bool ValidType(int32_t type) {
     return type >= DONT_FILTER && type <= FILTER_ALL;
   }
 
-  static Type FromInt(int32 type) {
+  static Type FromInt(int32_t type) {
     return static_cast<Type>(type);
   }
 
  private:
   // Don't instantiate this class.
   FilterPolicy();
   ~FilterPolicy();
 
--- a/ipc/chromium/src/chrome/common/gears_api.h
+++ b/ipc/chromium/src/chrome/common/gears_api.h
@@ -75,17 +75,17 @@ typedef struct _GearsShortcutData2 {
 } GearsShortcutData2;
 
 // Command data for GEARSPLUGINCOMMAND_GET_SHORTCUT_LIST.
 typedef struct _GearsShortcutList {
   // Note: these are output params, set by Gears.  There are no input params.
   // Memory for these shortcuts, including the strings they hold, should be
   // freed by the browser using CPB_Free.
   GearsShortcutData* shortcuts;  // array of installed shortcuts
-  uint32 num_shortcuts;  // size of the array
+  uint32_t num_shortcuts;  // size of the array
 } GearsShortcutList;
 
 // Command data for GEARSBROWSERCOMMAND_CREATE_SHORTCUT_DONE
 typedef struct _GearsCreateShortcutResult {
   GearsShortcutData2* shortcut;  // pointer to struct passed to
                                  // GEARSPLUGINCOMMAND_CREATE_SHORTCUT
   CPError result;  // CPERR_SUCCESS if shortcut was created, or error otherwise
 } GearsCreateShortcutResult;
--- a/ipc/chromium/src/chrome/common/gfx/color_utils.cc
+++ b/ipc/chromium/src/chrome/common/gfx/color_utils.cc
@@ -27,32 +27,32 @@ namespace color_utils {
 // See also:
 // http://www.brucelindbloom.com/index.html?ColorCalculator.html
 
 static const double kCIEConversionAlpha = 0.055;
 static const double kCIEConversionGamma = 2.2;
 static const double kE = 0.008856;
 static const double kK = 903.3;
 
-static double CIEConvertNonLinear(uint8 color_component) {
+static double CIEConvertNonLinear(uint8_t color_component) {
   double color_component_d = static_cast<double>(color_component) / 255.0;
   if (color_component_d > 0.04045) {
     double base = (color_component_d + kCIEConversionAlpha) /
                       (1 + kCIEConversionAlpha);
     return pow(base, kCIEConversionGamma);
   } else {
     return color_component_d / 12.92;
   }
 }
 
 // Note: this works only for sRGB.
 void SkColorToCIEXYZ(SkColor c, CIE_XYZ* xyz) {
-  uint8 r = SkColorGetR(c);
-  uint8 g = SkColorGetG(c);
-  uint8 b = SkColorGetB(c);
+  uint8_t r = SkColorGetR(c);
+  uint8_t g = SkColorGetG(c);
+  uint8_t b = SkColorGetB(c);
 
   xyz->X =
     0.4124 * CIEConvertNonLinear(r) +
     0.3576 * CIEConvertNonLinear(g) +
     0.1805 * CIEConvertNonLinear(b);
   xyz->Y =
     0.2126 * CIEConvertNonLinear(r) +
     0.7152 * CIEConvertNonLinear(g) +
@@ -77,35 +77,35 @@ void CIEXYZToLabColor(const CIE_XYZ& xyz
   double fx = LabConvertNonLinear(xyz.X / white_xyz.X);
   double fy = LabConvertNonLinear(xyz.Y / white_xyz.Y);
   double fz = LabConvertNonLinear(xyz.Z / white_xyz.Z);
   lab->L = static_cast<int>(116 * fy) - 16;
   lab->a = static_cast<int>(500 * (fx - fy));
   lab->b = static_cast<int>(200 * (fy - fz));
 }
 
-static uint8 sRGBColorComponentFromLinearComponent(double component) {
+static uint8_t sRGBColorComponentFromLinearComponent(double component) {
   double result;
   if (component <= 0.0031308) {
     result = 12.92 * component;
   } else {
     result = (1 + kCIEConversionAlpha) *
                  pow(component, (static_cast<double>(1) / 2.4)) -
                  kCIEConversionAlpha;
   }
-  return std::min(static_cast<uint8>(255), static_cast<uint8>(result * 255));
+  return std::min(static_cast<uint8_t>(255), static_cast<uint8_t>(result * 255));
 }
 
 SkColor CIEXYZToSkColor(SkAlpha alpha, const CIE_XYZ& xyz) {
   double r_linear = 3.2410 * xyz.X - 1.5374 * xyz.Y - 0.4986 * xyz.Z;
   double g_linear = -0.9692 * xyz.X + 1.8760 * xyz.Y + 0.0416 * xyz.Z;
   double b_linear = 0.0556 * xyz.X - 0.2040 * xyz.Y + 1.0570 * xyz.Z;
-  uint8 r = sRGBColorComponentFromLinearComponent(r_linear);
-  uint8 g = sRGBColorComponentFromLinearComponent(g_linear);
-  uint8 b = sRGBColorComponentFromLinearComponent(b_linear);
+  uint8_t r = sRGBColorComponentFromLinearComponent(r_linear);
+  uint8_t g = sRGBColorComponentFromLinearComponent(g_linear);
+  uint8_t b = sRGBColorComponentFromLinearComponent(b_linear);
   return SkColorSetARGB(alpha, r, g, b);
 }
 
 static double gen_yr(const LabColor& lab) {
   if (lab.L > (kE * kK))
     return pow((lab.L + 16.0) / 116, 3.0);
   return static_cast<double>(lab.L) / kK;
 }
--- a/ipc/chromium/src/chrome/common/gfx/emf.cc
+++ b/ipc/chromium/src/chrome/common/gfx/emf.cc
@@ -105,17 +105,17 @@ bool Emf::GetData(void* buffer, size_t s
   DCHECK(emf_ && !hdc_);
   DCHECK(buffer && size);
   unsigned size2 = GetEnhMetaFileBits(emf_, static_cast<unsigned>(size),
                                       reinterpret_cast<BYTE*>(buffer));
   DCHECK(size2 == size);
   return size2 == size && size2 != 0;
 }
 
-bool Emf::GetData(std::vector<uint8>* buffer) const {
+bool Emf::GetData(std::vector<uint8_t>* buffer) const {
   unsigned size = GetDataSize();
   if (!size)
     return false;
 
   buffer->resize(size);
   if (!GetData(&buffer->front(), size))
     return false;
   return true;
@@ -124,17 +124,17 @@ bool Emf::GetData(std::vector<uint8>* bu
 bool Emf::SaveTo(const std::wstring& filename) const {
   HANDLE file = CreateFile(filename.c_str(), GENERIC_WRITE,
                            FILE_SHARE_READ | FILE_SHARE_WRITE, NULL,
                            CREATE_ALWAYS, 0, NULL);
   if (file == INVALID_HANDLE_VALUE)
     return false;
 
   bool success = false;
-  std::vector<uint8> buffer;
+  std::vector<uint8_t> buffer;
   if (GetData(&buffer)) {
     DWORD written = 0;
     if (WriteFile(file, &*buffer.begin(), static_cast<DWORD>(buffer.size()),
                   &written, NULL) &&
         written == buffer.size()) {
       success = true;
     }
   }
--- a/ipc/chromium/src/chrome/common/gfx/emf.h
+++ b/ipc/chromium/src/chrome/common/gfx/emf.h
@@ -67,17 +67,17 @@ class Emf {
 
   // Retrieves the EMF stream size.
   unsigned GetDataSize() const;
 
   // Retrieves the EMF stream.
   bool GetData(void* buffer, size_t size) const;
 
   // Retrieves the EMF stream. It is an helper function.
-  bool GetData(std::vector<uint8>* buffer) const;
+  bool GetData(std::vector<uint8_t>* buffer) const;
 
   HENHMETAFILE emf() const {
     return emf_;
   }
 
   HDC hdc() const {
     return hdc_;
   }
--- a/ipc/chromium/src/chrome/common/ipc_channel.h
+++ b/ipc/chromium/src/chrome/common/ipc_channel.h
@@ -22,17 +22,17 @@ class Channel : public Message::Sender {
    public:
     virtual ~Listener() {}
 
     // Called when a message is received.
     virtual void OnMessageReceived(const Message& message) = 0;
 
     // Called when the channel is connected and we have received the internal
     // Hello message from the peer.
-    virtual void OnChannelConnected(int32 peer_pid) {}
+    virtual void OnChannelConnected(int32_t peer_pid) {}
 
     // Called when an error is detected that causes the channel to close.
     // This method is not called when a channel is closed normally.
     virtual void OnChannelError() {}
 
     // If the listener has queued messages, swap them for |queue| like so
     //   swap(impl->my_queued_messages, queue);
     virtual void GetQueuedMessages(std::queue<Message>& queue) {}
@@ -125,17 +125,17 @@ class Channel : public Message::Sender {
   class ChannelImpl;
   ChannelImpl *channel_impl_;
 
   // The Hello message is internal to the Channel class.  It is sent
   // by the peer when the channel is connected.  The message contains
   // just the process id (pid).  The message has a special routing_id
   // (MSG_ROUTING_NONE) and type (HELLO_MESSAGE_TYPE).
   enum {
-    HELLO_MESSAGE_TYPE = kuint16max  // Maximum value of message type (uint16),
+    HELLO_MESSAGE_TYPE = kuint16max  // Maximum value of message type (uint16_t),
                                      // to avoid conflicting with normal
                                      // message types, which are enumeration
                                      // constants starting from 0.
   };
 };
 
 }  // namespace IPC
 
--- a/ipc/chromium/src/chrome/common/ipc_channel_proxy.cc
+++ b/ipc/chromium/src/chrome/common/ipc_channel_proxy.cc
@@ -64,17 +64,17 @@ void ChannelProxy::Context::OnMessageRec
   // this thread is active.  That should be a reasonable assumption, but it
   // feels risky.  We may want to invent some more indirect way of referring to
   // a MessageLoop if this becomes a problem.
   listener_message_loop_->PostTask(FROM_HERE, NewRunnableMethod(
       this, &Context::OnDispatchMessage, message));
 }
 
 // Called on the IPC::Channel thread
-void ChannelProxy::Context::OnChannelConnected(int32 peer_pid) {
+void ChannelProxy::Context::OnChannelConnected(int32_t peer_pid) {
   peer_pid_ = peer_pid;
   for (size_t i = 0; i < filters_.size(); ++i)
     filters_[i]->OnChannelConnected(peer_pid);
 
   // See above comment about using listener_message_loop_ here.
   listener_message_loop_->PostTask(FROM_HERE, NewRunnableMethod(
       this, &Context::OnDispatchConnected));
 }
--- a/ipc/chromium/src/chrome/common/ipc_channel_proxy.h
+++ b/ipc/chromium/src/chrome/common/ipc_channel_proxy.h
@@ -57,17 +57,17 @@ class ChannelProxy : public Message::Sen
 
     // Called on the background thread when the filter has been removed from
     // the ChannelProxy and when the Channel is closing.  After a filter is
     // removed, it will not be called again.
     virtual void OnFilterRemoved() {}
 
     // Called to inform the filter that the IPC channel is connected and we
     // have received the internal Hello message from the peer.
-    virtual void OnChannelConnected(int32 peer_pid) {}
+    virtual void OnChannelConnected(int32_t peer_pid) {}
 
     // Called when there is an error on the channel, typically that the channel
     // has been closed.
     virtual void OnChannelError() {}
 
     // Called to inform the filter that the IPC channel will be destroyed.
     // OnFilterRemoved is called immediately after this.
     virtual void OnChannelClosing() {}
@@ -144,17 +144,17 @@ class ChannelProxy : public Message::Sen
     const std::wstring& channel_id() const { return channel_id_; }
 
     // Dispatches a message on the listener thread.
     void OnDispatchMessage(const Message& message);
 
    protected:
     // IPC::Channel::Listener methods:
     virtual void OnMessageReceived(const Message& message);
-    virtual void OnChannelConnected(int32 peer_pid);
+    virtual void OnChannelConnected(int32_t peer_pid);
     virtual void OnChannelError();
 
     // Like OnMessageReceived but doesn't try the filters.
     void OnMessageReceivedNoFilter(const Message& message);
 
     // Gives the filters a chance at processing |message|.
     // Returns true if the message was processed, false otherwise.
     bool TryFilters(const Message& message);
--- a/ipc/chromium/src/chrome/common/ipc_fuzzing_tests.cc
+++ b/ipc/chromium/src/chrome/common/ipc_fuzzing_tests.cc
@@ -14,30 +14,30 @@
 #include "chrome/common/ipc_channel_proxy.h"
 #include "chrome/common/ipc_message_utils.h"
 #include "chrome/common/ipc_tests.h"
 #include "testing/gtest/include/gtest/gtest.h"
 #include "testing/multiprocess_func_list.h"
 
 TEST(IPCMessageIntegrity, ReadBeyondBufferStr) {
   //This was BUG 984408.
-  uint32 v1 = kuint32max - 1;
+  uint32_t v1 = kuint32max - 1;
   int v2 = 666;
   IPC::Message m(0, 1, IPC::Message::PRIORITY_NORMAL);
   EXPECT_TRUE(m.WriteInt(v1));
   EXPECT_TRUE(m.WriteInt(v2));
 
   void* iter = NULL;
   std::string vs;
   EXPECT_FALSE(m.ReadString(&iter, &vs));
 }
 
 TEST(IPCMessageIntegrity, ReadBeyondBufferWStr) {
   //This was BUG 984408.
-  uint32 v1 = kuint32max - 1;
+  uint32_t v1 = kuint32max - 1;
   int v2 = 777;
   IPC::Message m(0, 1, IPC::Message::PRIORITY_NORMAL);
   EXPECT_TRUE(m.WriteInt(v1));
   EXPECT_TRUE(m.WriteInt(v2));
 
   void* iter = NULL;
   std::wstring vs;
   EXPECT_FALSE(m.ReadWString(&iter, &vs));
@@ -72,31 +72,31 @@ TEST(IPCMessageIntegrity, ReadVectorNega
 TEST(IPCMessageIntegrity, ReadVectorTooLarge1) {
   // This was BUG 1006367. This is the large but positive length case. Again
   // we try to hit the non-specialized case vector<P>.
   IPC::Message m(0, 1, IPC::Message::PRIORITY_NORMAL);
   EXPECT_TRUE(m.WriteInt(0x21000003));   // This is the count of elements.
   EXPECT_TRUE(m.WriteInt64(1));
   EXPECT_TRUE(m.WriteInt64(2));
 
-  std::vector<int64> vec;
+  std::vector<int64_t> vec;
   void* iter = 0;
   EXPECT_FALSE(ReadParam(&m, &iter, &vec));
 }
 
 TEST(IPCMessageIntegrity, ReadVectorTooLarge2) {
   // This was BUG 1006367. This is the large but positive with an additional
   // integer overflow when computing the actual byte size. Again we try to hit
   // the non-specialized case vector<P>.
   IPC::Message m(0, 1, IPC::Message::PRIORITY_NORMAL);
   EXPECT_TRUE(m.WriteInt(0x71000000));   // This is the count of elements.
   EXPECT_TRUE(m.WriteInt64(1));
   EXPECT_TRUE(m.WriteInt64(2));
 
-  std::vector<int64> vec;
+  std::vector<int64_t> vec;
   void* iter = 0;
   EXPECT_FALSE(ReadParam(&m, &iter, &vec));
 }
 
 // We don't actually use the messages defined in this file, but we do this
 // to get to the IPC macros.
 #define MESSAGES_INTERNAL_FILE "chrome/common/ipc_sync_message_unittest.h"
 #include "chrome/common/ipc_message_macros.h"
--- a/ipc/chromium/src/chrome/common/ipc_logging.cc
+++ b/ipc/chromium/src/chrome/common/ipc_logging.cc
@@ -214,17 +214,17 @@ void Logging::OnPostDispatchMessage(cons
   if (MessageLoop::current() == main_thread_) {
     Log(data);
   } else {
     main_thread_->PostTask(FROM_HERE, NewRunnableMethod(
         this, &Logging::Log, data));
   }
 }
 
-void Logging::GetMessageText(uint16 type, std::wstring* name,
+void Logging::GetMessageText(uint16_t type, std::wstring* name,
                              const Message* message,
                              std::wstring* params) {
   if (!log_function_mapping_)
     return;
 
   int message_class = type >> 12;
   if (log_function_mapping_[message_class] != NULL) {
     log_function_mapping_[message_class](type, name, message, params);
--- a/ipc/chromium/src/chrome/common/ipc_logging.h
+++ b/ipc/chromium/src/chrome/common/ipc_logging.h
@@ -58,26 +58,26 @@ class Logging : public base::WaitableEve
   // Returns the name of the logging enabled/disabled events so that the
   // sandbox can add them to to the policy.  If true, gets the name of the
   // enabled event, if false, gets the name of the disabled event.
   static std::wstring GetEventName(bool enabled);
 
   // Like the *MsgLog functions declared for each message class, except this
   // calls the correct one based on the message type automatically.  Defined in
   // ipc_logging.cc.
-  static void GetMessageText(uint16 type, std::wstring* name,
+  static void GetMessageText(uint16_t type, std::wstring* name,
                              const Message* message, std::wstring* params);
 
   // WaitableEventWatcher::Delegate implementation
   void OnWaitableEventSignaled(base::WaitableEvent* event);
 
   // MessageLoop::DestructionObserver implementation
   void WillDestroyCurrentMessageLoop();
 
-  typedef void (*LogFunction)(uint16 type,
+  typedef void (*LogFunction)(uint16_t type,
                              std::wstring* name,
                              const Message* msg,
                              std::wstring* params);
 
   static void SetLoggerFunctions(LogFunction *functions);
 
  private:
   friend struct DefaultSingletonTraits<Logging>;
--- a/ipc/chromium/src/chrome/common/ipc_message.cc
+++ b/ipc/chromium/src/chrome/common/ipc_message.cc
@@ -22,29 +22,29 @@ Message::Message()
     : Pickle(sizeof(Header)) {
   header()->routing = header()->type = header()->flags = 0;
 #if defined(OS_POSIX)
   header()->num_fds = 0;
 #endif
   InitLoggingVariables();
 }
 
-Message::Message(int32 routing_id, msgid_t type, PriorityValue priority,
+Message::Message(int32_t routing_id, msgid_t type, PriorityValue priority,
                  MessageCompression compression, const char* const name)
     : Pickle(sizeof(Header)) {
   header()->routing = routing_id;
   header()->type = type;
   header()->flags = priority;
   if (compression == COMPRESSION_ENABLED)
     header()->flags |= COMPRESS_BIT;
 #if defined(OS_POSIX)
   header()->num_fds = 0;
 #endif
-  header()->rpc_remote_stack_depth_guess = static_cast<uint32>(-1);
-  header()->rpc_local_stack_depth = static_cast<uint32>(-1);
+  header()->rpc_remote_stack_depth_guess = static_cast<uint32_t>(-1);
+  header()->rpc_local_stack_depth = static_cast<uint32_t>(-1);
   header()->seqno = 0;
   InitLoggingVariables(name);
 }
 
 Message::Message(const char* data, int data_len) : Pickle(data, data_len) {
   InitLoggingVariables();
 }
 
@@ -69,32 +69,32 @@ Message& Message::operator=(const Messag
   InitLoggingVariables(other.name_);
 #if defined(OS_POSIX)
   file_descriptor_set_ = other.file_descriptor_set_;
 #endif
   return *this;
 }
 
 #ifdef IPC_MESSAGE_LOG_ENABLED
-void Message::set_sent_time(int64 time) {
+void Message::set_sent_time(int64_t time) {
   DCHECK((header()->flags & HAS_SENT_TIME_BIT) == 0);
   header()->flags |= HAS_SENT_TIME_BIT;
   WriteInt64(time);
 }
 
-int64 Message::sent_time() const {
+int64_t Message::sent_time() const {
   if ((header()->flags & HAS_SENT_TIME_BIT) == 0)
     return 0;
 
   const char* data = end_of_payload();
-  data -= sizeof(int64);
-  return *(reinterpret_cast<const int64*>(data));
+  data -= sizeof(int64_t);
+  return *(reinterpret_cast<const int64_t*>(data));
 }
 
-void Message::set_received_time(int64 time) const {
+void Message::set_received_time(int64_t time) const {
   received_time_ = time;
 }
 #endif
 
 #if defined(OS_POSIX)
 bool Message::WriteFileDescriptor(const base::FileDescriptor& descriptor) {
   // We write the index of the descriptor so that we don't have to
   // keep the current descriptor as extra decoding state when deserialising.
--- a/ipc/chromium/src/chrome/common/ipc_message.h
+++ b/ipc/chromium/src/chrome/common/ipc_message.h
@@ -29,17 +29,17 @@ namespace IPC {
 //------------------------------------------------------------------------------
 
 class Channel;
 class Message;
 struct LogData;
 
 class Message : public Pickle {
  public:
-  typedef uint32 msgid_t;
+  typedef uint32_t msgid_t;
 
   // Implemented by objects that can send IPC messages across a channel.
   class Sender {
    public:
     virtual ~Sender() {}
 
     // Sends the given IPC message.  The implementor takes ownership of the
     // given Message regardless of whether or not this method succeeds.  This
@@ -60,17 +60,17 @@ class Message : public Pickle {
   };
 
   virtual ~Message();
 
   Message();
 
   // Initialize a message with a user-defined type, priority value, and
   // destination WebView ID.
-  Message(int32 routing_id, msgid_t type, PriorityValue priority,
+  Message(int32_t routing_id, msgid_t type, PriorityValue priority,
           MessageCompression compression = COMPRESSION_NONE,
           const char* const name="???");
 
   // Initializes a message from a const block of data.  The data is not copied;
   // instead the data is merely referenced by this message.  Only const methods
   // should be used on the message when initialized this way.
   Message(const char* data, int data_len);
 
@@ -135,47 +135,47 @@ class Message : public Pickle {
   bool is_caller_pumping_messages() const {
     return (header()->flags & PUMPING_MSGS_BIT) != 0;
   }
 
   msgid_t type() const {
     return header()->type;
   }
 
-  int32 routing_id() const {
+  int32_t routing_id() const {
     return header()->routing;
   }
 
-  void set_routing_id(int32 new_id) {
+  void set_routing_id(int32_t new_id) {
     header()->routing = new_id;
   }
 
-  uint32 rpc_remote_stack_depth_guess() const {
+  uint32_t rpc_remote_stack_depth_guess() const {
     return header()->rpc_remote_stack_depth_guess;
   }
 
-  void set_rpc_remote_stack_depth_guess(uint32 depth) {
+  void set_rpc_remote_stack_depth_guess(uint32_t depth) {
     DCHECK(is_rpc());
     header()->rpc_remote_stack_depth_guess = depth;
   }
 
-  uint32 rpc_local_stack_depth() const {
+  uint32_t rpc_local_stack_depth() const {
     return header()->rpc_local_stack_depth;
   }
 
-  void set_rpc_local_stack_depth(uint32 depth) {
+  void set_rpc_local_stack_depth(uint32_t depth) {
     DCHECK(is_rpc());
     header()->rpc_local_stack_depth = depth;
   }
 
-  int32 seqno() const {
+  int32_t seqno() const {
     return header()->seqno;
   }
 
-  void set_seqno(int32 seqno) {
+  void set_seqno(int32_t seqno) {
     header()->seqno = seqno;
   }
 
   const char* const name() const {
     return name_;
   }
 
   void set_name(const char* const name) {
@@ -227,21 +227,21 @@ class Message : public Pickle {
   // Get a file descriptor from the message. Returns false on error.
   //   iter: a Pickle iterator to the current location in the message.
   bool ReadFileDescriptor(void** iter, base::FileDescriptor* descriptor) const;
 #endif
 
 #ifdef IPC_MESSAGE_LOG_ENABLED
   // Adds the outgoing time from Time::Now() at the end of the message and sets
   // a bit to indicate that it's been added.
-  void set_sent_time(int64 time);
-  int64 sent_time() const;
+  void set_sent_time(int64_t time);
+  int64_t sent_time() const;
 
-  void set_received_time(int64 time) const;
-  int64 received_time() const { return received_time_; }
+  void set_received_time(int64_t time) const;
+  int64_t received_time() const { return received_time_; }
   void set_output_params(const std::wstring& op) const { output_params_ = op; }
   const std::wstring& output_params() const { return output_params_; }
   // The following four functions are needed so we can log sync messages with
   // delayed replies.  We stick the log data from the sent message into the
   // reply message, so that when it's sent and we have the output parameters
   // we can log it.  As such, we set a flag on the sent message to not log it.
   void set_sync_log_data(LogData* data) const { log_data_ = data; }
   LogData* sync_log_data() const { return log_data_; }
@@ -275,28 +275,28 @@ class Message : public Pickle {
     PUMPING_MSGS_BIT= 0x0040,
     HAS_SENT_TIME_BIT = 0x0080,
     RPC_BIT         = 0x0100,
     COMPRESS_BIT    = 0x0200
   };
 
 #pragma pack(push, 2)
   struct Header : Pickle::Header {
-    int32 routing;  // ID of the view that this message is destined for
+    int32_t routing;  // ID of the view that this message is destined for
     msgid_t type;   // specifies the user-defined message type
-    uint32 flags;   // specifies control flags for the message
+    uint32_t flags;   // specifies control flags for the message
 #if defined(OS_POSIX)
-    uint32 num_fds; // the number of descriptors included with this message
+    uint32_t num_fds; // the number of descriptors included with this message
 #endif
     // For RPC messages, a guess at what the *other* side's stack depth is.
-    uint32 rpc_remote_stack_depth_guess;
+    uint32_t rpc_remote_stack_depth_guess;
     // The actual local stack depth.
-    uint32 rpc_local_stack_depth;
+    uint32_t rpc_local_stack_depth;
     // Sequence number
-    int32 seqno;
+    int32_t seqno;
   };
 #pragma pack(pop)
 
   Header* header() {
     return headerT<Header>();
   }
   const Header* header() const {
     return headerT<Header>();
@@ -319,17 +319,17 @@ class Message : public Pickle {
     return file_descriptor_set_.get();
   }
 #endif
 
   const char* name_;
 
 #ifdef IPC_MESSAGE_LOG_ENABLED
   // Used for logging.
-  mutable int64 received_time_;
+  mutable int64_t received_time_;
   mutable std::wstring output_params_;
   mutable LogData* log_data_;
   mutable bool dont_log_;
 #endif
 };
 
 //------------------------------------------------------------------------------
 
--- a/ipc/chromium/src/chrome/common/ipc_message_macros.h
+++ b/ipc/chromium/src/chrome/common/ipc_message_macros.h
@@ -381,27 +381,27 @@ void class_name::OnMessageReceived(const
   } \
 }
 
 #elif defined(IPC_MESSAGE_MACROS_LOG)
 #undef IPC_MESSAGE_MACROS_LOG
 
 #ifndef IPC_LOG_TABLE_CREATED
 #define IPC_LOG_TABLE_CREATED
-typedef void (*LogFunction)(uint16 type,
+typedef void (*LogFunction)(uint16_t type,
                            std::wstring* name,
                            const IPC::Message* msg,
                            std::wstring* params);
 
 LogFunction g_log_function_mapping[LastMsgIndex];
 #endif
 
 
 #define IPC_BEGIN_MESSAGES(label) \
-  void label##MsgLog(uint16 type, std::wstring* name, const IPC::Message* msg, std::wstring* params) { \
+  void label##MsgLog(uint16_t type, std::wstring* name, const IPC::Message* msg, std::wstring* params) { \
   switch (type) {
 
 #define IPC_END_MESSAGES(label) \
      default: \
       if (name) \
         *name = L"[UNKNOWN " L ## #label L" MSG"; \
     } \
   } \
@@ -645,78 +645,78 @@ LogFunction g_log_function_mapping[LastM
             ID, \
             MakeTuple(arg1, arg2, arg3, arg4, arg5)) {} \
   };
 
 #define IPC_MESSAGE_ROUTED0(msg_class) \
   class msg_class : public IPC::Message { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id) \
+    msg_class(int32_t routing_id) \
         : IPC::Message(routing_id, ID, PRIORITY_NORMAL) {} \
   };
 
 #define IPC_MESSAGE_ROUTED1(msg_class, type1) \
   class msg_class : public IPC::MessageWithTuple<type1> { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id, const type1& arg1) \
+    msg_class(int32_t routing_id, const type1& arg1) \
         : IPC::MessageWithTuple<type1>(routing_id, ID, arg1) {} \
   };
 
 #define IPC_MESSAGE_ROUTED2(msg_class, type1, type2) \
   class msg_class : public IPC::MessageWithTuple< Tuple2<type1, type2> > { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id, const type1& arg1, const type2& arg2) \
+    msg_class(int32_t routing_id, const type1& arg1, const type2& arg2) \
         : IPC::MessageWithTuple< Tuple2<type1, type2> >( \
             routing_id, ID, MakeTuple(arg1, arg2)) {} \
   };
 
 #define IPC_MESSAGE_ROUTED3(msg_class, type1, type2, type3) \
   class msg_class : \
       public IPC::MessageWithTuple< Tuple3<type1, type2, type3> > { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \
+    msg_class(int32_t routing_id, const type1& arg1, const type2& arg2, \
               const type3& arg3) \
         : IPC::MessageWithTuple< Tuple3<type1, type2, type3> >( \
             routing_id, ID, MakeTuple(arg1, arg2, arg3)) {} \
   };
 
 #define IPC_MESSAGE_ROUTED4(msg_class, type1, type2, type3, type4) \
   class msg_class : \
       public IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> > { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \
+    msg_class(int32_t routing_id, const type1& arg1, const type2& arg2, \
                const type3& arg3, const type4& arg4) \
         : IPC::MessageWithTuple< Tuple4<type1, type2, type3, type4> >( \
             routing_id, ID, MakeTuple(arg1, arg2, arg3, arg4)) {} \
   };
 
 #define IPC_MESSAGE_ROUTED5(msg_class, type1, type2, type3, type4, type5) \
   class msg_class : \
       public IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, type5> > { \
    public: \
     enum { ID = msg_class##__ID }; \
-    msg_class(int32 routing_id, const type1& arg1, const type2& arg2, \
+    msg_class(int32_t routing_id, const type1& arg1, const type2& arg2, \
               const type3& arg3, const type4& arg4, const type5& arg5) \
         : IPC::MessageWithTuple< Tuple5<type1, type2, type3, type4, type5> >( \
             routing_id, ID, MakeTuple(arg1, arg2, arg3, arg4, arg5)) {} \
   };
 
 #define IPC_MESSAGE_ROUTED6(msg_class, type1, type2, type3, type4, type5, \
                             type6)                                      \
   class msg_class :                                                     \
       public IPC::MessageWithTuple< Tuple6<type1, type2, type3, type4, type5, \
                                            type6> > {                   \
  public:                                                                \
     enum { ID = msg_class##__ID };                                      \
-    msg_class(int32 routing_id, const type1& arg1, const type2& arg2,   \
+    msg_class(int32_t routing_id, const type1& arg1, const type2& arg2,   \
               const type3& arg3, const type4& arg4, const type5& arg5,  \
               const type6& arg6)                                        \
       : IPC::MessageWithTuple< Tuple6<type1, type2, type3, type4, type5, \
       type6> >(                                                         \
           routing_id, ID, MakeTuple(arg1, arg2, arg3, arg4, arg5, arg6)) {} \
   };
 
 #define IPC_SYNC_MESSAGE_CONTROL0_0(msg_class) \
--- a/ipc/chromium/src/chrome/common/ipc_message_utils.cc
+++ b/ipc/chromium/src/chrome/common/ipc_message_utils.cc
@@ -15,23 +15,23 @@ namespace IPC {
 
 namespace {
 
 struct SkBitmap_Data {
   // The configuration for the bitmap (bits per pixel, etc).
   SkBitmap::Config fConfig;
 
   // The width of the bitmap in pixels.
-  uint32 fWidth;
+  uint32_t fWidth;
 
   // The height of the bitmap in pixels.
-  uint32 fHeight;
+  uint32_t fHeight;
 
   // The number of bytes between subsequent rows of the bitmap.
-  uint32 fRowBytes;
+  uint32_t fRowBytes;
 
   void InitSkBitmapDataForTransfer(const SkBitmap& bitmap) {
     fConfig = bitmap.config();
     fWidth = bitmap.width();
     fHeight = bitmap.height();
     fRowBytes = bitmap.rowBytes();
   }
 
--- a/ipc/chromium/src/chrome/common/ipc_message_utils.h
+++ b/ipc/chromium/src/chrome/common/ipc_message_utils.h
@@ -95,32 +95,32 @@ struct ParamTraits<bool> {
     return m->ReadBool(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(p ? L"true" : L"false");
   }
 };
 
 template <>
-struct ParamTraits<int16> {
-  typedef int16 param_type;
+struct ParamTraits<int16_t> {
+  typedef int16_t param_type;
   static void Write(Message* m, const param_type& p) {
     m->WriteInt(p);
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
     return m->ReadInt16(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%hd", p));
   }
 };
 
 template <>
-struct ParamTraits<uint16> {
-  typedef uint16 param_type;
+struct ParamTraits<uint16_t> {
+  typedef uint16_t param_type;
   static void Write(Message* m, const param_type& p) {
     m->WriteInt(p);
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
     return m->ReadUInt16(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%hu", p));
@@ -233,73 +233,73 @@ struct ParamTraits<size_t> {
     l->append(StringPrintf(L"%u", p));
   }
 };
 
 #elif !defined(OS_MACOSX)
 // ... so we need to define traits for |unsigned int|.
 // XXX duplicating OS_MACOSX version below so as not to conflict
 template <>
-struct ParamTraits<uint32> {
-  typedef uint32 param_type;
+struct ParamTraits<uint32_t> {
+  typedef uint32_t param_type;
   static void Write(Message* m, const param_type& p) {
     m->WriteUInt32(p);
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
     return m->ReadUInt32(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%u", p));
   }
 };
 
 #endif // if !(defined(OS_LINUX) && defined(ARCH_CPU_64_BITS))
 
 #if defined(OS_MACOSX)
-// On Linux size_t & uint32 can be the same type.
+// On Linux size_t & uint32_t can be the same type.
 // TODO(playmobil): Fix compilation if this is not the case.
 template <>
-struct ParamTraits<uint32> {
-  typedef uint32 param_type;
+struct ParamTraits<uint32_t> {
+  typedef uint32_t param_type;
   static void Write(Message* m, const param_type& p) {
     m->WriteUInt32(p);
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
     return m->ReadUInt32(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%u", p));
   }
 };
 #endif  // defined(OS_MACOSX)
 
 #if !((defined(OS_BSD) || defined(OS_LINUX)) && defined(ARCH_CPU_64_BITS))
-// int64 is |long int| on 64-bit systems, uint64 is |unsigned long|
+// int64_t is |long int| on 64-bit systems, uint64_t is |unsigned long|
 template <>
-struct ParamTraits<int64> {
-  typedef int64 param_type;
+struct ParamTraits<int64_t> {
+  typedef int64_t param_type;
   static void Write(Message* m, const param_type& p) {
     m->WriteInt64(p);
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
     return m->ReadInt64(iter, r);
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%" PRId64L, p));
   }
 };
 
 template <>
-struct ParamTraits<uint64> {
-  typedef uint64 param_type;
+struct ParamTraits<uint64_t> {
+  typedef uint64_t param_type;
   static void Write(Message* m, const param_type& p) {
-    m->WriteInt64(static_cast<int64>(p));
+    m->WriteInt64(static_cast<int64_t>(p));
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
-    return m->ReadInt64(iter, reinterpret_cast<int64*>(r));
+    return m->ReadInt64(iter, reinterpret_cast<int64_t*>(r));
   }
   static void Log(const param_type& p, std::wstring* l) {
     l->append(StringPrintf(L"%" PRIu64L, p));
   }
 };
 #endif // if !(defined(OS_LINUX) && defined(ARCH_CPU_64_BITS))
 
 template <>
@@ -325,27 +325,27 @@ struct ParamTraits<double> {
     l->append(StringPrintf(L"e", p));
   }
 };
 
 template <>
 struct ParamTraits<base::Time> {
   typedef base::Time param_type;
   static void Write(Message* m, const param_type& p) {
-    ParamTraits<int64>::Write(m, p.ToInternalValue());
+    ParamTraits<int64_t>::Write(m, p.ToInternalValue());
   }
   static bool Read(const Message* m, void** iter, param_type* r) {
-    int64 value;
-    if (!ParamTraits<int64>::Read(m, iter, &value))
+    int64_t value;
+    if (!ParamTraits<int64_t>::Read(m, iter, &value))
       return false;
     *r = base::Time::FromInternalValue(value);
     return true;
   }
   static void Log(const param_type& p, std::wstring* l) {
-    ParamTraits<int64>::Log(p.ToInternalValue(), l);
+    ParamTraits<int64_t>::Log(p.ToInternalValue(), l);
   }
 };
 
 #if defined(OS_WIN)
 template <>
 struct ParamTraits<LOGFONT> {
   typedef LOGFONT param_type;
   static void Write(Message* m, const param_type& p) {
@@ -763,23 +763,23 @@ struct ParamTraits<XFORM> {
   static void Log(const param_type& p, std::wstring* l) {
     l->append(L"<XFORM>");
   }
 };
 #endif  // defined(OS_WIN)
 
 struct LogData {
   std::wstring channel;
-  int32 routing_id;
-  uint16 type;
+  int32_t routing_id;
+  uint16_t type;
   std::wstring flags;
-  int64 sent;  // Time that the message was sent (i.e. at Send()).
-  int64 receive;  // Time before it was dispatched (i.e. before calling
+  int64_t sent;  // Time that the message was sent (i.e. at Send()).
+  int64_t receive;  // Time before it was dispatched (i.e. before calling
                   // OnMessageReceived).
-  int64 dispatch;  // Time after it was dispatched (i.e. after calling
+  int64_t dispatch;  // Time after it was dispatched (i.e. after calling
                    // OnMessageReceived).
   std::wstring message_name;
   std::wstring params;
 };
 
 template <>
 struct ParamTraits<LogData> {
   typedef LogData param_type;
@@ -799,17 +799,17 @@ struct ParamTraits<LogData> {
       ReadParam(m, iter, &r->channel) &&
       ReadParam(m, iter, &r->routing_id) &&
       ReadParam(m, iter, &type) &&
       ReadParam(m, iter, &r->flags) &&
       ReadParam(m, iter, &r->sent) &&
       ReadParam(m, iter, &r->receive) &&
       ReadParam(m, iter, &r->dispatch) &&
       ReadParam(m, iter, &r->params);
-    r->type = static_cast<uint16>(type);
+    r->type = static_cast<uint16_t>(type);
     return result;
   }
   static void Log(const param_type& p, std::wstring* l) {
     // Doesn't make sense to implement this!
   }
 };
 
 #if defined(OS_WIN)
@@ -1017,17 +1017,17 @@ struct ParamTraits< Tuple6<A, B, C, D, E
 // Generic message subclasses
 
 // Used for asynchronous messages.
 template <class ParamType>
 class MessageWithTuple : public Message {
  public:
   typedef ParamType Param;
 
-  MessageWithTuple(int32 routing_id, uint16 type, const Param& p)
+  MessageWithTuple(int32_t routing_id, uint16_t type, const Param& p)
       : Message(routing_id, type, PRIORITY_NORMAL) {
     WriteParam(this, p);
   }
 
   static bool Read(const Message* msg, Param* p) {
     void* iter = NULL;
     bool rv = ReadParam(msg, &iter, p);
     DCHECK(rv) << "Error deserializing message " << msg->type();
@@ -1179,17 +1179,17 @@ void GenerateLogData(const std::wstring&
 
 // Used for synchronous messages.
 template <class SendParamType, class ReplyParamType>
 class MessageWithReply : public SyncMessage {
  public:
   typedef SendParamType SendParam;
   typedef ReplyParamType ReplyParam;
 
-  MessageWithReply(int32 routing_id, uint16 type,
+  MessageWithReply(int32_t routing_id, uint16_t type,
                    const SendParam& send, const ReplyParam& reply)
       : SyncMessage(routing_id, type, PRIORITY_NORMAL,
                     new ParamDeserializer<ReplyParam>(reply)) {
     WriteParam(this, send);
   }
 
   static void Log(const Message* msg, std::wstring* l) {
     if (msg->is_sync()) {
--- a/ipc/chromium/src/chrome/common/ipc_sync_message.cc
+++ b/ipc/chromium/src/chrome/common/ipc_sync_message.cc
@@ -10,24 +10,24 @@
 #include <stack>
 
 #include "base/logging.h"
 #include "base/waitable_event.h"
 #include "chrome/common/ipc_sync_message.h"
 
 namespace IPC {
 
-uint32 SyncMessage::next_id_ = 0;
+uint32_t SyncMessage::next_id_ = 0;
 #define kSyncMessageHeaderSize 4
 
 base::WaitableEvent* dummy_event = new base::WaitableEvent(true, true);
 
 SyncMessage::SyncMessage(
-    int32 routing_id,
-    uint16 type,
+    int32_t routing_id,
+    uint16_t type,
     PriorityValue priority,
     MessageReplyDeserializer* deserializer)
     : Message(routing_id, type, priority),
       deserializer_(deserializer),
       pump_messages_event_(NULL)
       {
   set_sync();
   set_unblock(true);
--- a/ipc/chromium/src/chrome/common/ipc_sync_message.h
+++ b/ipc/chromium/src/chrome/common/ipc_sync_message.h
@@ -17,17 +17,17 @@ class WaitableEvent;
 }
 
 namespace IPC {
 
 class MessageReplyDeserializer;
 
 class SyncMessage : public Message {
  public:
-  SyncMessage(int32 routing_id, uint16 type, PriorityValue priority,
+  SyncMessage(int32_t routing_id, uint16_t type, PriorityValue priority,
               MessageReplyDeserializer* deserializer);
 
   // Call this to get a deserializer for the output parameters.
   // Note that this can only be called once, and the caller is responsible
   // for deleting the deserializer when they're done.
   MessageReplyDeserializer* GetReplyDeserializer();
 
   // If this message can cause the receiver to block while waiting for user
@@ -73,17 +73,17 @@ class SyncMessage : public Message {
   };
 
   static bool ReadSyncHeader(const Message& msg, SyncHeader* header);
   static bool WriteSyncHeader(Message* msg, const SyncHeader& header);
 
   MessageReplyDeserializer* deserializer_;
   base::WaitableEvent* pump_messages_event_;
 
-  static uint32 next_id_;  // for generation of unique ids
+  static uint32_t next_id_;  // for generation of unique ids
 };
 
 // Used to deserialize parameters from a reply to a synchronous message
 class MessageReplyDeserializer {
  public:
   bool SerializeOutputParameters(const Message& msg);
  private:
   // Derived classes need to implement this, using the given iterator (which
--- a/ipc/chromium/src/chrome/common/ipc_test_sink.cc
+++ b/ipc/chromium/src/chrome/common/ipc_test_sink.cc
@@ -21,25 +21,25 @@ void TestSink::ClearMessages() {
 }
 
 const Message* TestSink::GetMessageAt(size_t index) const {
   if (index >= messages_.size())
     return NULL;
   return &messages_[index];
 }
 
-const Message* TestSink::GetFirstMessageMatching(uint16 id) const {
+const Message* TestSink::GetFirstMessageMatching(uint16_t id) const {
   for (size_t i = 0; i < messages_.size(); i++) {
     if (messages_[i].type() == id)
       return &messages_[i];
   }
   return NULL;
 }
 
-const Message* TestSink::GetUniqueMessageMatching(uint16 id) const {
+const Message* TestSink::GetUniqueMessageMatching(uint16_t id) const {
   size_t found_index = 0;
   size_t found_count = 0;
   for (size_t i = 0; i < messages_.size(); i++) {
     if (messages_[i].type() == id) {
       found_count++;
       found_index = i;
     }
   }
--- a/ipc/chromium/src/chrome/common/ipc_test_sink.h
+++ b/ipc/chromium/src/chrome/common/ipc_test_sink.h
@@ -58,24 +58,24 @@ class TestSink {
   // Returns the message at the given index in the queue. The index may be out
   // of range, in which case the return value is NULL. The returned pointer will
   // only be valid until another message is received or the list is cleared.
   const Message* GetMessageAt(size_t index) const;
 
   // Returns the first message with the given ID in the queue. If there is no
   // message with the given ID, returns NULL. The returned pointer will only be
   // valid until another message is received or the list is cleared.
-  const Message* GetFirstMessageMatching(uint16 id) const;
+  const Message* GetFirstMessageMatching(uint16_t id) const;
 
   // Returns the message with the given ID in the queue. If there is no such
   // message or there is more than one of that message, this will return NULL
   // (with the expectation that you'll do an ASSERT_TRUE() on the result).
   // The returned pointer will only be valid until another message is received
   // or the list is cleared.
-  const Message* GetUniqueMessageMatching(uint16 id) const;
+  const Message* GetUniqueMessageMatching(uint16_t id) const;
 
  private:
   // The actual list of received messages.
   std::vector<Message> messages_;
 
   DISALLOW_COPY_AND_ASSIGN(TestSink);
 };
 
--- a/ipc/chromium/src/chrome/common/message_router.cc
+++ b/ipc/chromium/src/chrome/common/message_router.cc
@@ -10,22 +10,22 @@ void MessageRouter::OnControlMessageRece
 }
 
 bool MessageRouter::Send(IPC::Message* msg) {
   NOTREACHED() <<
       "should override in subclass if you care about sending messages";
   return false;
 }
 
-void MessageRouter::AddRoute(int32 routing_id,
+void MessageRouter::AddRoute(int32_t routing_id,
                              IPC::Channel::Listener* listener) {
   routes_.AddWithID(listener, routing_id);
 }
 
-void MessageRouter::RemoveRoute(int32 routing_id) {
+void MessageRouter::RemoveRoute(int32_t routing_id) {
   routes_.Remove(routing_id);
 }
 
 void MessageRouter::OnMessageReceived(const IPC::Message& msg) {
   if (msg.routing_id() == MSG_ROUTING_CONTROL) {
     OnControlMessageReceived(msg);
   } else {
     RouteMessage(msg);
--- a/ipc/chromium/src/chrome/common/message_router.h
+++ b/ipc/chromium/src/chrome/common/message_router.h
@@ -42,18 +42,18 @@ class MessageRouter : public IPC::Channe
   // true if the message was dispatched, or false if there was no listener for
   // that route id.
   virtual bool RouteMessage(const IPC::Message& msg);
 
   // IPC::Message::Sender implementation:
   virtual bool Send(IPC::Message* msg);
 
   // Called to add/remove a listener for a particular message routing ID.
-  void AddRoute(int32 routing_id, IPC::Channel::Listener* listener);
-  void RemoveRoute(int32 routing_id);
+  void AddRoute(int32_t routing_id, IPC::Channel::Listener* listener);
+  void RemoveRoute(int32_t routing_id);
 
  private:
   // A list of all listeners with assigned routing IDs.
   IDMap<IPC::Channel::Listener> routes_;
 
   DISALLOW_EVIL_CONSTRUCTORS(MessageRouter);
 };
 
--- a/ipc/chromium/src/chrome/common/page_transition_types.h
+++ b/ipc/chromium/src/chrome/common/page_transition_types.h
@@ -121,47 +121,47 @@ class PageTransition {
 
     // General mask defining the bits used for the qualifiers.
     QUALIFIER_MASK = 0xFFFFFF00
   };
 
   // The type used for the bitfield.
   typedef unsigned int Type;
 
-  static bool ValidType(int32 type) {
+  static bool ValidType(int32_t type) {
     Type t = StripQualifier(static_cast<Type>(type));
     return (t >= 0 && t <= LAST_CORE);
   }
 
-  static Type FromInt(int32 type) {
+  static Type FromInt(int32_t type) {
     if (!ValidType(type)) {
       NOTREACHED() << "Invalid transition type " << type;
 
       // Return a safe default so we don't have corrupt data in release mode.
       return LINK;
     }
     return static_cast<Type>(type);
   }
 
   // Returns true if the given transition is a top-level frame transition, or
   // false if the transition was for a subframe.
   static bool IsMainFrame(Type type) {
-    int32 t = StripQualifier(type);
+    int32_t t = StripQualifier(type);
     return (t != AUTO_SUBFRAME && t != MANUAL_SUBFRAME);
   }
 
   // Returns whether a transition involves a redirection
   static bool IsRedirect(Type type) {
     return (type & IS_REDIRECT_MASK) != 0;
   }
 
   // Simplifies the provided transition by removing any qualifier
   static Type StripQualifier(Type type) {
     return static_cast<Type>(type & ~QUALIFIER_MASK);
   }
 
   // Return the qualifier
-  static int32 GetQualifier(Type type) {
+  static int32_t GetQualifier(Type type) {
     return type & QUALIFIER_MASK;
   }
 };
 
 #endif  // CHROME_COMMON_PAGE_TRANSITION_TYPES_H__
--- a/ipc/chromium/src/chrome/common/plugin_messages.h
+++ b/ipc/chromium/src/chrome/common/plugin_messages.h
@@ -57,18 +57,18 @@ struct PluginMsg_URLRequestReply_Params 
   intptr_t notify_data;
   intptr_t stream;
 };
 
 struct PluginMsg_DidReceiveResponseParams {
   int id;
   std::string mime_type;
   std::string headers;
-  uint32 expected_length;
-  uint32 last_modified;
+  uint32_t expected_length;
+  uint32_t last_modified;
   bool request_is_seekable;
 };
 
 struct NPIdentifier_Param {
   NPIdentifier identifier;
 };
 
 enum NPVariant_ParamEnum {
--- a/ipc/chromium/src/chrome/common/plugin_messages_internal.h
+++ b/ipc/chromium/src/chrome/common/plugin_messages_internal.h
@@ -12,17 +12,17 @@ IPC_BEGIN_MESSAGES(PluginProcess)
   // renderer.  The channel name is returned in a
   // PluginProcessHostMsg_ChannelCreated message.
   IPC_MESSAGE_CONTROL1(PluginProcessMsg_CreateChannel,
                        bool /* off_the_record */)
 
   // Allows a chrome plugin loaded in the browser process to send arbitrary
   // data to an instance of the same plugin loaded in a plugin process.
   IPC_MESSAGE_CONTROL1(PluginProcessMsg_PluginMessage,
-                       std::vector<uint8> /* opaque data */)
+                       std::vector<uint8_t> /* opaque data */)
 
   // The following messages are used by all child processes, even though they
   // are listed under PluginProcess.  It seems overkill to define ChildProcess.
   // Tells the child process it should stop.
   IPC_MESSAGE_CONTROL0(PluginProcessMsg_AskBeforeShutdown)
 
   // Sent in response to PluginProcessHostMsg_ShutdownRequest to tell the child
   // process that it's safe to shutdown.
@@ -42,28 +42,28 @@ IPC_BEGIN_MESSAGES(PluginProcessHost)
   IPC_SYNC_MESSAGE_CONTROL0_1(PluginProcessHostMsg_GetPluginFinderUrl,
                               std::string /* plugin finder URL */)
 
   IPC_MESSAGE_CONTROL0(PluginProcessHostMsg_ShutdownRequest)
 
   // Allows a chrome plugin loaded in a plugin process to send arbitrary
   // data to an instance of the same plugin loaded in the browser process.
   IPC_MESSAGE_CONTROL1(PluginProcessHostMsg_PluginMessage,
-                       std::vector<uint8> /* opaque data */)
+                       std::vector<uint8_t> /* opaque data */)
 
   // Allows a chrome plugin loaded in a plugin process to send arbitrary
   // data to an instance of the same plugin loaded in the browser process.
   IPC_SYNC_MESSAGE_CONTROL1_1(PluginProcessHostMsg_PluginSyncMessage,
-                              std::vector<uint8> /* opaque data */,
-                              std::vector<uint8> /* opaque data response */)
+                              std::vector<uint8_t> /* opaque data */,
+                              std::vector<uint8_t> /* opaque data response */)
 
   // Used to get cookies for the given URL.  The request_context is a
-  // CPBrowsingContext, but is passed as int32 to avoid compilation errors.
+  // CPBrowsingContext, but is passed as int32_t to avoid compilation errors.
   IPC_SYNC_MESSAGE_CONTROL2_1(PluginProcessHostMsg_GetCookies,
-                              int32 /* request_context */,
+                              int32_t /* request_context */,
                               GURL /* url */,
                               std::string /* cookies */)
 
   // Get the list of proxies to use for |url|, as a semicolon delimited list
   // of "<TYPE> <HOST>:<PORT>" | "DIRECT". See also ViewHostMsg_ResolveProxy
   // which does the same thing.
   IPC_SYNC_MESSAGE_CONTROL1_2(PluginProcessHostMsg_ResolveProxy,
                               GURL /* url */,
@@ -258,17 +258,17 @@ IPC_BEGIN_MESSAGES(PluginHost)
                               int /* height */,
                               std::string /* json_arguments */,
                               std::string /* json_retval */)
 
   IPC_MESSAGE_ROUTED1(PluginHostMsg_MissingPluginStatus,
                       int /* status */)
 
   IPC_SYNC_MESSAGE_ROUTED0_1(PluginHostMsg_GetCPBrowsingContext,
-                             uint32 /* context */)
+                             uint32_t /* context */)
 
   IPC_MESSAGE_ROUTED0(PluginHostMsg_CancelDocumentLoad)
 
   IPC_MESSAGE_ROUTED5(PluginHostMsg_InitiateHTTPRangeRequest,
                       std::string /* url */,
                       std::string /* range_info */,
                       intptr_t    /* existing_stream */,
                       bool        /* notify_needed */,
--- a/ipc/chromium/src/chrome/common/pref_service.cc
+++ b/ipc/chromium/src/chrome/common/pref_service.cc
@@ -515,17 +515,17 @@ void PrefService::SetFilePath(const wcha
 
   scoped_ptr<Value> old_value(GetPrefCopy(path));
   bool rv = persistent_->SetString(path, value.value());
   DCHECK(rv);
 
   FireObserversIfChanged(path, old_value.get());
 }
 
-void PrefService::SetInt64(const wchar_t* path, int64 value) {
+void PrefService::SetInt64(const wchar_t* path, int64_t value) {
   DCHECK(CalledOnValidThread());
 
   const Preference* pref = FindPreference(path);
   if (!pref) {
     NOTREACHED() << "Trying to write an unregistered pref: " << path;
     return;
   }
   if (pref->type() != Value::TYPE_STRING) {
@@ -535,34 +535,34 @@ void PrefService::SetInt64(const wchar_t
 
   scoped_ptr<Value> old_value(GetPrefCopy(path));
   bool rv = persistent_->SetString(path, Int64ToWString(value));
   DCHECK(rv);
 
   FireObserversIfChanged(path, old_value.get());
 }
 
-int64 PrefService::GetInt64(const wchar_t* path) const {
+int64_t PrefService::GetInt64(const wchar_t* path) const {
   DCHECK(CalledOnValidThread());
 
   std::wstring result;
   if (transient_->GetString(path, &result))
     return StringToInt64(WideToUTF16Hack(result));
 
   const Preference* pref = FindPreference(path);
   if (!pref) {
     NOTREACHED() << "Trying to read an unregistered pref: " << path;
     return StringToInt64(WideToUTF16Hack(result));
   }
   bool rv = pref->GetValue()->GetAsString(&result);
   DCHECK(rv);
   return StringToInt64(WideToUTF16Hack(result));
 }
 
-void PrefService::RegisterInt64Pref(const wchar_t* path, int64 default_value) {
+void PrefService::RegisterInt64Pref(const wchar_t* path, int64_t default_value) {
   Preference* pref = new Preference(persistent_.get(), path,
       Value::CreateStringValue(Int64ToWString(default_value)));
   RegisterPreference(pref);
 }
 
 DictionaryValue* PrefService::GetMutableDictionary(const wchar_t* path) {
   DCHECK(CalledOnValidThread());
 
--- a/ipc/chromium/src/chrome/common/pref_service.h
+++ b/ipc/chromium/src/chrome/common/pref_service.h
@@ -154,19 +154,19 @@ class PrefService : public NonThreadSafe
   void SetInteger(const wchar_t* path, int value);
   void SetReal(const wchar_t* path, double value);
   void SetString(const wchar_t* path, const std::wstring& value);
   void SetFilePath(const wchar_t* path, const FilePath& value);
 
   // Int64 helper methods that actually store the given value as a string.
   // Note that if obtaining the named value via GetDictionary or GetList, the
   // Value type will be TYPE_STRING.
-  void SetInt64(const wchar_t* path, int64 value);
-  int64 GetInt64(const wchar_t* path) const;
-  void RegisterInt64Pref(const wchar_t* path, int64 default_value);
+  void SetInt64(const wchar_t* path, int64_t value);
+  int64_t GetInt64(const wchar_t* path) const;
+  void RegisterInt64Pref(const wchar_t* path, int64_t default_value);
 
   // Used to set the value of dictionary or list values in the pref tree.  This
   // will create a dictionary or list if one does not exist in the pref tree.
   // This method returns NULL only if you're requesting an unregistered pref or
   // a non-dict/non-list pref.
   // WARNING: Changes to the dictionary or list will not automatically notify
   // pref observers. TODO(tc): come up with a way to still fire observers.
   DictionaryValue* GetMutableDictionary(const wchar_t* path);
--- a/ipc/chromium/src/chrome/common/render_messages.h
+++ b/ipc/chromium/src/chrome/common/render_messages.h
@@ -49,17 +49,17 @@ class Time;
 
 // Parameters structure for ViewMsg_Navigate, which has too many data
 // parameters to be reasonably put in a predefined IPC message.
 struct ViewMsg_Navigate_Params {
   // The page_id for this navigation, or -1 if it is a new navigation.  Back,
   // Forward, and Reload navigations should have a valid page_id.  If the load
   // succeeds, then this page_id will be reflected in the resultant
   // ViewHostMsg_FrameNavigate message.
-  int32 page_id;
+  int32_t page_id;
 
   // The URL to load.
   GURL url;
 
   // The URL to send in the "Referer" header field. Can be empty if there is
   // no referrer.
   GURL referrer;
 
@@ -79,17 +79,17 @@ struct ViewMsg_Navigate_Params {
 
 // Parameters structure for ViewHostMsg_FrameNavigate, which has too many data
 // parameters to be reasonably put in a predefined IPC message.
 struct ViewHostMsg_FrameNavigate_Params {
   // Page ID of this navigation. The renderer creates a new unique page ID
   // anytime a new session history entry is created. This means you'll get new
   // page IDs for user actions, and the old page IDs will be reloaded when
   // iframes are loaded automatically.
-  int32 page_id;
+  int32_t page_id;
 
   // URL of the page being loaded.
   GURL url;
 
   // URL of the referrer of this load. WebKit generates this based on the
   // source of the event that caused the load.
   GURL referrer;
 
@@ -254,21 +254,21 @@ struct ViewHostMsg_Resource_Request {
   // Process ID of process that originated this request.
   int origin_pid;
 
   // What this resource load is for (main frame, sub-frame, sub-resource,
   // object).
   ResourceType::Type resource_type;
 
   // Used by plugin->browser requests to get the correct URLRequestContext.
-  uint32 request_context;
+  uint32_t request_context;
 
   // Indicates which frame (or worker context) the request is being loaded into,
   // or kNoAppCacheContextId.
-  int32 app_cache_context_id;
+  int32_t app_cache_context_id;
 
   // Optional upload data (may be null).
   scoped_refptr<net::UploadData> upload_data;
 };
 
 // Parameters for a render request.
 struct ViewMsg_Print_Params {
   // In pixels according to dpi_x and dpi_y.
@@ -1057,17 +1057,17 @@ struct ParamTraits<net::UploadData::Elem
       const char* data;
       int len;
       if (!m->ReadData(iter, &data, &len))
         return false;
       r->SetToBytes(data, len);
     } else {
       DCHECK(type == net::UploadData::TYPE_FILE);
       FilePath file_path;
-      uint64 offset, length;
+      uint64_t offset, length;
       if (!ReadParam(m, iter, &file_path))
         return false;
       if (!ReadParam(m, iter, &offset))
         return false;
       if (!ReadParam(m, iter, &length))
         return false;
       r->SetToFilePathRange(file_path, offset, length);
     }
--- a/ipc/chromium/src/chrome/common/render_messages_internal.h
+++ b/ipc/chromium/src/chrome/common/render_messages_internal.h
@@ -30,26 +30,26 @@
 //-----------------------------------------------------------------------------
 // RenderView messages
 // These are messages sent from the browser to the renderer process.
 
 IPC_BEGIN_MESSAGES(View)
   // Used typically when recovering from a crash.  The new rendering process
   // sets its global "next page id" counter to the given value.
   IPC_MESSAGE_CONTROL1(ViewMsg_SetNextPageID,
-                       int32 /* next_page_id */)
+                       int32_t /* next_page_id */)
 
   // Tells the renderer to create a new view.
   // This message is slightly different, the view it takes is the view to
   // create, the message itself is sent as a non-view control message.
   IPC_MESSAGE_CONTROL4(ViewMsg_New,
                        gfx::NativeViewId, /* parent window */
                        ModalDialogEvent, /* model dialog box event */
                        WebPreferences,
-                       int32 /* view id */)
+                       int32_t /* view id */)
 
   // Tells the renderer to set its maximum cache size to the supplied value
   IPC_MESSAGE_CONTROL3(ViewMsg_SetCacheCapacities,
                        size_t /* min_dead_capacity */,
                        size_t /* max_dead_capacity */,
                        size_t /* capacity */)
 
   // Reply in response to ViewHostMsg_ShowView or ViewHostMsg_ShowWidget.
@@ -168,24 +168,24 @@ IPC_BEGIN_MESSAGES(View)
   IPC_MESSAGE_ROUTED2(ViewMsg_Resource_ReceivedResponse,
                       int /* request_id */,
                       ResourceResponseHead)
 
   // Sent as download progress is being made, size of the resource may be
   // unknown, in that case |size| is -1.
   IPC_MESSAGE_ROUTED3(ViewMsg_Resource_DownloadProgress,
                       int /* request_id */,
-                      int64 /* position */,
-                      int64 /* size */)
+                      int64_t /* position */,
+                      int64_t /* size */)
 
   // Sent as upload progress is being made.
   IPC_MESSAGE_ROUTED3(ViewMsg_Resource_UploadProgress,
                       int /* request_id */,
-                      int64 /* position */,
-                      int64 /* size */)
+                      int64_t /* position */,
+                      int64_t /* size */)
 
   // Sent when the request has been redirected.
   IPC_MESSAGE_ROUTED2(ViewMsg_Resource_ReceivedRedirect,
                       int /* request_id */,
                       GURL /* new_url */)
 
   // Sent when some data from a resource request is ready. The handle should
   // already be mapped into the process that receives this message.
@@ -418,17 +418,17 @@ IPC_BEGIN_MESSAGES(View)
   // which contain all resource links that have local copy.
   IPC_MESSAGE_ROUTED3(ViewMsg_GetSerializedHtmlDataForCurrentPageWithLocalLinks,
                       std::vector<GURL> /* urls that have local copy */,
                       std::vector<FilePath> /* paths of local copy */,
                       FilePath /* local directory path */)
 
   // Requests application info for the page. The renderer responds back with
   // ViewHostMsg_DidGetApplicationInfo.
-  IPC_MESSAGE_ROUTED1(ViewMsg_GetApplicationInfo, int32 /*page_id*/)
+  IPC_MESSAGE_ROUTED1(ViewMsg_GetApplicationInfo, int32_t /*page_id*/)
 
   // Requests the renderer to download the specified image encode it as PNG
   // and send the PNG data back ala ViewHostMsg_DidDownloadImage.
   IPC_MESSAGE_ROUTED3(ViewMsg_DownloadImage,
                       int /* identifier for the request */,
                       GURL /* URL of the image */,
                       int /* Size of the image. Normally 0, but set if you have
                              a preferred image size to request, such as when
@@ -478,22 +478,22 @@ IPC_BEGIN_MESSAGES(View)
   IPC_MESSAGE_ROUTED0(ViewMsg_DisassociateFromPopupCount)
 
   // Notifies the renderer of the AppCache that has been selected for a
   // a particular context (or frame). This is sent in reply to
   // one of the two AppCacheMsg_SelectAppCache messages.
   IPC_MESSAGE_CONTROL3(AppCacheMsg_AppCacheSelected,
                        int /* context_id */,
                        int /* select_request_id */,
-                       int64 /* cache_id */)
+                       int64_t /* cache_id */)
 
   // Reply to the ViewHostMsg_QueryFormFieldAutofill message with the autofill
   // suggestions.
   IPC_MESSAGE_ROUTED4(ViewMsg_AutofillSuggestions,
-                      int64 /* id of the text input field */,
+                      int64_t /* id of the text input field */,
                       int /* id of the request message */,
                       std::vector<std::wstring> /* suggestions */,
                       int /* index of default suggestion */)
 
   // Sent by the Browser process to alert a window about whether a blocked
   // popup notification is visible. The renderer assumes every new window is a
   // blocked popup until notified otherwise.
   IPC_MESSAGE_ROUTED1(ViewMsg_PopupNotificationVisiblityChanged,
@@ -648,32 +648,32 @@ IPC_BEGIN_MESSAGES(ViewHost)
   // has a lot of parameters and is packed/unpacked by functions defined in
   // render_messages.h.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_FrameNavigate,
                       ViewHostMsg_FrameNavigate_Params)
 
   // Notifies the browser that we have session history information.
   // page_id: unique ID that allows us to distinguish between history entries.
   IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateState,
-                      int32 /* page_id */,
+                      int32_t /* page_id */,
                       std::string /* state */)
 
   // Changes the title for the page in the UI when the page is navigated or the
   // title changes.
   // TODO(darin): use a UTF-8 string to reduce data size
-  IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateTitle, int32, std::wstring)
+  IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateTitle, int32_t, std::wstring)
 
   // Change the encoding name of the page in UI when the page has detected
   // proper encoding name.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_UpdateEncoding,
                       std::wstring /* new encoding name */)
 
   // Notifies the browser that we want to show a destination url for a potential
   // action (e.g. when the user is hovering over a link).
-  IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateTargetURL, int32, GURL)
+  IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateTargetURL, int32_t, GURL)
 
   // Sent when the renderer starts loading the page. This corresponds to
   // WebKit's notion of the throbber starting. Note that sometimes you may get
   // duplicates of these during a single load.
   IPC_MESSAGE_ROUTED0(ViewHostMsg_DidStartLoading)
 
   // Sent when the renderer is done loading a page. This corresponds to WebKit's
   // noption of the throbber stopping.
@@ -786,24 +786,24 @@ IPC_BEGIN_MESSAGES(ViewHost)
   // Retrieve the data directory associated with the renderer's profile.
   IPC_SYNC_MESSAGE_CONTROL0_1(ViewHostMsg_GetDataDir,
                               std::wstring /* data_dir_retval */)
 
   // Allows a chrome plugin loaded in a renderer process to send arbitrary
   // data to an instance of the same plugin loaded in the browser process.
   IPC_MESSAGE_CONTROL2(ViewHostMsg_PluginMessage,
                        FilePath /* plugin_path of plugin */,
-                       std::vector<uint8> /* opaque data */)
+                       std::vector<uint8_t> /* opaque data */)
 
   // Allows a chrome plugin loaded in a renderer process to send arbitrary
   // data to an instance of the same plugin loaded in the browser process.
   IPC_SYNC_MESSAGE_CONTROL2_1(ViewHostMsg_PluginSyncMessage,
                               FilePath /* plugin_path of plugin */,
-                              std::vector<uint8> /* opaque data */,
-                              std::vector<uint8> /* opaque data */)
+                              std::vector<uint8_t> /* opaque data */,
+                              std::vector<uint8_t> /* opaque data */)
 
   // Requests spellcheck for a word.
   IPC_SYNC_MESSAGE_ROUTED1_2(ViewHostMsg_SpellCheck,
                              std::wstring /* word to check */,
                              int /* misspell location */,
                              int /* misspell length */)
 
   // Initiate a download based on user actions like 'ALT+click'.
@@ -821,28 +821,28 @@ IPC_BEGIN_MESSAGES(ViewHost)
                              std::wstring /* in - default prompt */,
                              GURL         /* in - originating page URL */,
                              int          /* in - dialog flags */,
                              bool         /* out - success */,
                              std::wstring /* out - prompt field */)
 
   // Sets the contents for the given page (URL and page ID are the first two
   // arguments) given the contents that is the 3rd.
-  IPC_MESSAGE_CONTROL3(ViewHostMsg_PageContents, GURL, int32, std::wstring)
+  IPC_MESSAGE_CONTROL3(ViewHostMsg_PageContents, GURL, int32_t, std::wstring)
 
   // Specifies the URL as the first parameter (a wstring) and thumbnail as
   // binary data as the second parameter.
   IPC_MESSAGE_ROUTED3(ViewHostMsg_Thumbnail,
                       GURL /* url */,
                       ThumbnailScore /* score */,
                       SkBitmap /* bitmap */)
 
   // Notification that the url for the favicon of a site has been determined.
   IPC_MESSAGE_ROUTED2(ViewHostMsg_UpdateFavIconURL,
-                      int32 /* page_id */,
+                      int32_t /* page_id */,
                       GURL /* url of the favicon */)
 
   // Request that the browser get the text from the selection clipboard and send
   // it back to the renderer via ViewMsg_SelectionClipboardResponse.
   IPC_MESSAGE_ROUTED0(ViewHostMsg_PasteFromSelectionClipboard)
 
   // Used to tell the parent that the user right clicked on an area of the
   // content area, and a context menu should be shown for it. The params
@@ -965,17 +965,17 @@ IPC_BEGIN_MESSAGES(ViewHost)
 
   // Tells the browser to move the focus to the next (previous if reverse is
   // true) focusable element.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_TakeFocus, bool /* reverse */)
 
   // Notification that the page has an OpenSearch description document
   // associated with it.
   IPC_MESSAGE_ROUTED3(ViewHostMsg_PageHasOSDD,
-                      int32 /* page_id */,
+                      int32_t /* page_id */,
                       GURL /* url of OS description document */,
                       bool /* autodetected */)
 
   // required for synchronizing IME windows.
   // Parameters
   // * control (ViewHostMsg_ImeControl)
   //   It specifies the code for controlling the IME attached to
   //   the browser process. This parameter should be one of the values
@@ -1046,17 +1046,17 @@ IPC_BEGIN_MESSAGES(ViewHost)
                              ViewMsg_PrintPages_Params /* settings choosen by
                                                           the user*/)
 #endif  // defined(OS_WIN)
 
   // WebKit and JavaScript error messages to log to the console
   // or debugger UI.
   IPC_MESSAGE_ROUTED3(ViewHostMsg_AddMessageToConsole,
                       std::wstring, /* msg */
-                      int32, /* line number */
+                      int32_t, /* line number */
                       std::wstring /* source id */)
 
   // Response message for ViewMsg_DebugAttach.
   IPC_MESSAGE_ROUTED0(ViewHostMsg_DidDebugAttach)
 
   // WebKit and JavaScript error messages to log to the console
   // or debugger UI.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_DebuggerOutput,
@@ -1112,27 +1112,27 @@ IPC_BEGIN_MESSAGES(ViewHost)
   IPC_MESSAGE_ROUTED3(ViewHostMsg_SendCurrentPageAllSavableResourceLinks,
                       std::vector<GURL> /* all savable resource links */,
                       std::vector<GURL> /* all referrers of resource links */,
                       std::vector<GURL> /* all frame links */)
 
   IPC_MESSAGE_ROUTED3(ViewHostMsg_SendSerializedHtmlData,
                       GURL /* frame's url */,
                       std::string /* data buffer */,
-                      int32 /* complete status */)
+                      int32_t /* complete status */)
 
   IPC_SYNC_MESSAGE_ROUTED4_1(ViewHostMsg_ShowModalHTMLDialog,
                              GURL /* url */,
                              int /* width */,
                              int /* height */,
                              std::string /* json_arguments */,
                              std::string /* json_retval */)
 
   IPC_MESSAGE_ROUTED2(ViewHostMsg_DidGetApplicationInfo,
-                      int32 /* page_id */,
+                      int32_t /* page_id */,
                       webkit_glue::WebApplicationInfo)
 
   // Provides the result from running OnMsgShouldClose.  |proceed| matches the
   // return value of the the frame's shouldClose method (which includes the
   // onbeforeunload handler): true if the user decided to proceed with leaving
   // the page.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_ShouldClose_ACK,
                       bool /* proceed */)
@@ -1158,17 +1158,17 @@ IPC_BEGIN_MESSAGES(ViewHost)
                               std::string /* mime_type */)
   IPC_SYNC_MESSAGE_CONTROL1_1(ViewHostMsg_GetPreferredExtensionForMimeType,
                               std::string /* mime_type */,
                               FilePath::StringType /* extension */)
 
   // Get the CPBrowsingContext associated with the renderer sending this
   // message.
   IPC_SYNC_MESSAGE_CONTROL0_1(ViewHostMsg_GetCPBrowsingContext,
-                              uint32 /* context */)
+                              uint32_t /* context */)
 
   // Sent when the renderer process is done processing a DataReceived
   // message.
   IPC_MESSAGE_ROUTED1(ViewHostMsg_DataReceived_ACK,
                       int /* request_id */)
 
   // Sent when a provisional load on the main frame redirects.
   IPC_MESSAGE_ROUTED3(ViewHostMsg_DidRedirectProvisionalLoad,
@@ -1227,30 +1227,30 @@ IPC_BEGIN_MESSAGES(ViewHost)
   // 'document_url' the url of the main resource commited to the frame
   // 'cache_document_was_loaded_frame' the id of the appcache the main resource
   //    was loaded from or kNoAppCacheId
   // 'opt_manifest_url' the manifest url specified in the <html> tag if any
   IPC_MESSAGE_CONTROL5(AppCacheMsg_SelectAppCache,
                        int /* context_id */,
                        int /* select_request_id */,
                        GURL  /* document_url */,
-                       int64 /* cache_document_was_loaded_from */,
+                       int64_t /* cache_document_was_loaded_from */,
                        GURL  /* opt_manifest_url */)
 
   // Returns the resizer box location in the window this widget is embeded.
   // Important for Mac OS X, but not Win or Linux.
   IPC_SYNC_MESSAGE_ROUTED1_1(ViewHostMsg_GetRootWindowResizerRect,
                              gfx::NativeViewId /* window */,
                              gfx::Rect /* Out: Window location */)
 
   // Queries the browser for suggestion for autofill in a form input field.
   IPC_MESSAGE_ROUTED4(ViewHostMsg_QueryFormFieldAutofill,
                       std::wstring /* field name */,
                       std::wstring /* user entered text */,
-                      int64 /* id of the text input field */,
+                      int64_t /* id of the text input field */,
                       int /* id of this message */)
 
   // Instructs the browser to remove the specified autofill-entry from the
   // database.
   IPC_MESSAGE_ROUTED2(ViewHostMsg_RemoveAutofillEntry,
                       std::wstring /* field name */,
                       std::wstring /* value */)
 
--- a/ipc/chromium/src/chrome/common/resource_dispatcher.cc
+++ b/ipc/chromium/src/chrome/common/resource_dispatcher.cc
@@ -49,26 +49,26 @@ class IPCResourceLoaderBridge : public R
                           const GURL& policy_url,
                           const GURL& referrer,
                           const std::string& frame_origin,
                           const std::string& main_frame_origin,
                           const std::string& headers,
                           int load_flags,
                           int origin_pid,
                           ResourceType::Type resource_type,
-                          uint32 request_context,
+                          uint32_t request_context,
                           int app_cache_context_id,
                           int route_id);
   virtual ~IPCResourceLoaderBridge();
 
   // ResourceLoaderBridge
   virtual void AppendDataToUpload(const char* data, int data_len);
   virtual void AppendFileRangeToUpload(const FilePath& path,
-                                       uint64 offset, uint64 length);
-  virtual void SetUploadIdentifier(int64 identifier);
+                                       uint64_t offset, uint64_t length);
+  virtual void SetUploadIdentifier(int64_t identifier);
   virtual bool Start(Peer* peer);
   virtual void Cancel();
   virtual void SetDefersLoading(bool value);
   virtual void SyncLoad(SyncLoadResponse* response);
 
 #ifdef LOG_RESOURCE_REQUESTS
   const std::string& url() const { return url_; }
 #endif
@@ -103,17 +103,17 @@ IPCResourceLoaderBridge::IPCResourceLoad
     const GURL& policy_url,
     const GURL& referrer,
     const std::string& frame_origin,
     const std::string& main_frame_origin,
     const std::string& headers,
     int load_flags,
     int origin_pid,
     ResourceType::Type resource_type,
-    uint32 request_context,
+    uint32_t request_context,
     int app_cache_context_id,
     int route_id)
     : peer_(NULL),
       dispatcher_(dispatcher),
       request_id_(-1),
       route_id_(route_id) {
   DCHECK(dispatcher_) << "no resource dispatcher";
   request_.method = method;
@@ -153,25 +153,25 @@ void IPCResourceLoaderBridge::AppendData
     return;
 
   if (!request_.upload_data)
     request_.upload_data = new net::UploadData();
   request_.upload_data->AppendBytes(data, data_len);
 }
 
 void IPCResourceLoaderBridge::AppendFileRangeToUpload(
-    const FilePath& path, uint64 offset, uint64 length) {
+    const FilePath& path, uint64_t offset, uint64_t length) {
   DCHECK(request_id_ == -1) << "request already started";
 
   if (!request_.upload_data)
     request_.upload_data = new net::UploadData();
   request_.upload_data->AppendFileRange(path, offset, length);
 }
 
-void IPCResourceLoaderBridge::SetUploadIdentifier(int64 identifier) {
+void IPCResourceLoaderBridge::SetUploadIdentifier(int64_t identifier) {
   DCHECK(request_id_ == -1) << "request already started";
 
   if (!request_.upload_data)
     request_.upload_data = new net::UploadData();
   request_.upload_data->set_identifier(identifier);
 }
 
 // Writes a footer on the message and sends it
@@ -288,17 +288,17 @@ bool ResourceDispatcher::OnMessageReceiv
   if (!request_info.deferred_message_queue.empty())
     FlushDeferredMessages(request_id);
 
   DispatchMessage(message);
   return true;
 }
 
 void ResourceDispatcher::OnDownloadProgress(
-    const IPC::Message& message, int request_id, int64 position, int64 size) {
+    const IPC::Message& message, int request_id, int64_t position, int64_t size) {
   PendingRequestList::iterator it = pending_requests_.find(request_id);
   if (it == pending_requests_.end()) {
      DLOG(WARNING) << "Got download progress for a nonexistant or "
          " finished requests";
      return;
   }
 
   PendingRequestInfo& request_info = it->second;
@@ -311,17 +311,17 @@ void ResourceDispatcher::OnDownloadProgr
   IPC::Message::Sender* sender = message_sender();
   if (sender) {
     sender->Send(
         new ViewHostMsg_DownloadProgress_ACK(message.routing_id(), request_id));
   }
 }
 
 void ResourceDispatcher::OnUploadProgress(
-    const IPC::Message& message, int request_id, int64 position, int64 size) {
+    const IPC::Message& message, int request_id, int64_t position, int64_t size) {
   PendingRequestList::iterator it = pending_requests_.find(request_id);
   if (it == pending_requests_.end()) {
     // this might happen for kill()ed requests on the webkit end, so perhaps
     // it shouldn't be a warning...
     DLOG(WARNING) << "Got upload progress for a nonexistant or "
         "finished request";
     return;
   }
@@ -524,17 +524,17 @@ webkit_glue::ResourceLoaderBridge* Resou
     const GURL& policy_url,
     const GURL& referrer,
     const std::string& frame_origin,
     const std::string& main_frame_origin,
     const std::string& headers,
     int flags,
     int origin_pid,
     ResourceType::Type resource_type,
-    uint32 request_context,
+    uint32_t request_context,
     int app_cache_context_id,
     int route_id) {
   return new webkit_glue::IPCResourceLoaderBridge(this, method, url, policy_url,
                                                   referrer, frame_origin,
                                                   main_frame_origin, headers,
                                                   flags, origin_pid,
                                                   resource_type,
                                                   request_context,
--- a/ipc/chromium/src/chrome/common/resource_dispatcher.h
+++ b/ipc/chromium/src/chrome/common/resource_dispatcher.h
@@ -40,17 +40,17 @@ class ResourceDispatcher {
     const GURL& policy_url,
     const GURL& referrer,
     const std::string& frame_origin,
     const std::string& main_frame_origin,
     const std::string& headers,
     int load_flags,
     int origin_pid,
     ResourceType::Type resource_type,
-    uint32 request_context /* used for plugin->browser requests */,
+    uint32_t request_context /* used for plugin->browser requests */,
     int app_cache_context_id,
     int route_id);
 
   // Adds a request from the pending_requests_ list, returning the new
   // requests' ID
   int AddPendingRequest(webkit_glue::ResourceLoaderBridge::Peer* callback,
                         ResourceType::Type resource_type);
 
@@ -85,20 +85,20 @@ class ResourceDispatcher {
     MessageQueue deferred_message_queue;
     bool is_deferred;
   };
   typedef base::hash_map<int, PendingRequestInfo> PendingRequestList;
 
   // Message response handlers, called by the message handler for this process.
   void OnUploadProgress(const IPC::Message& message,
                         int request_id,
-                        int64 position,
-                        int64 size);
+                        int64_t position,
+                        int64_t size);
   void OnDownloadProgress(const IPC::Message& message,
-                          int request_id, int64 position, int64 size);
+                          int request_id, int64_t position, int64_t size);
   void OnReceivedResponse(int request_id, const ResourceResponseHead&);
   void OnReceivedRedirect(int request_id, const GURL& new_url);
   void OnReceivedData(const IPC::Message& message,
                       int request_id,
                       base::SharedMemoryHandle data,
                       int data_len);
   void OnRequestComplete(int request_id,
                          const URLRequestStatus& status,
--- a/ipc/chromium/src/chrome/common/resource_dispatcher_unittest.cc
+++ b/ipc/chromium/src/chrome/common/resource_dispatcher_unittest.cc
@@ -39,17 +39,17 @@ class TestRequestCallback : public Resou
       bool content_filtered) {
   }
 
   virtual void OnReceivedData(const char* data, int len) {
     EXPECT_FALSE(complete_);
     data_.append(data, len);
   }
 
-  virtual void OnUploadProgress(uint64 position, uint64 size) {
+  virtual void OnUploadProgress(uint64_t position, uint64_t size) {
   }
 
   virtual void OnCompletedRequest(const URLRequestStatus& status,
                                   const std::string& security_info) {
     EXPECT_FALSE(complete_);
     complete_ = true;
   }
 
--- a/ipc/chromium/src/chrome/common/security_filter_peer.cc
+++ b/ipc/chromium/src/chrome/common/security_filter_peer.cc
@@ -95,17 +95,17 @@ SecurityFilterPeer* SecurityFilterPeer::
   std::wstring error_msg = l10n_util::GetString(IDS_UNSAFE_FRAME_MESSAGE);
   std::string html = StringPrintf(
       "<html><body style='background-color:#990000;color:white;'>"
       "%s</body></html>",
       WideToUTF8(error_msg).c_str());
   return new ReplaceContentPeer(NULL, peer, "text/html", html);
 }
 
-void SecurityFilterPeer::OnUploadProgress(uint64 position, uint64 size) {
+void SecurityFilterPeer::OnUploadProgress(uint64_t position, uint64_t size) {
   original_peer_->OnUploadProgress(position, size);
 }
 
 void SecurityFilterPeer::OnReceivedRedirect(const GURL& new_url) {
   NOTREACHED();
 }
 
 void SecurityFilterPeer::OnReceivedResponse(
--- a/ipc/chromium/src/chrome/common/security_filter_peer.h
+++ b/ipc/chromium/src/chrome/common/security_filter_peer.h
@@ -33,17 +33,17 @@ class SecurityFilterPeer : public webkit
       webkit_glue::ResourceLoaderBridge::Peer* peer,
       int os_error);
 
   static SecurityFilterPeer* CreateSecurityFilterPeerForFrame(
       webkit_glue::ResourceLoaderBridge::Peer* peer,
       int os_error);
 
   // ResourceLoaderBridge::Peer methods.
-  virtual void OnUploadProgress(uint64 position, uint64 size);
+  virtual void OnUploadProgress(uint64_t position, uint64_t size);
   virtual void OnReceivedRedirect(const GURL& new_url);
   virtual void OnReceivedResponse(
       const webkit_glue::ResourceLoaderBridge::ResponseInfo& info,
       bool content_filtered);
   virtual void OnReceivedData(const char* data, int len);
   virtual void OnCompletedRequest(const URLRequestStatus& status,
                                   const std::string& security_info);
   virtual std::string GetURLForDebugging();
--- a/ipc/chromium/src/chrome/common/transport_dib.h
+++ b/ipc/chromium/src/chrome/common/transport_dib.h
@@ -45,46 +45,46 @@ class TransportDIB {
   //   4) Process A sends the Handle to B, but B incorrectly believes that it
   //      already has it cached.
   struct HandleAndSequenceNum {
     HandleAndSequenceNum()
         : handle(NULL),
           sequence_num(0) {
     }
 
-    HandleAndSequenceNum(HANDLE h, uint32 seq_num)
+    HandleAndSequenceNum(HANDLE h, uint32_t seq_num)
         : handle(h),
           sequence_num(seq_num) {
     }
 
     bool operator< (const HandleAndSequenceNum& other) const {
       // Use the lexicographic order on the tuple <handle, sequence_num>.
       if (other.handle != handle)
         return other.handle < handle;
       return other.sequence_num < sequence_num;
     }
 
     HANDLE handle;
-    uint32 sequence_num;
+    uint32_t sequence_num;
   };
   typedef HandleAndSequenceNum Id;
 #elif defined(OS_MACOSX) || defined(OS_BSD)
   typedef base::SharedMemoryHandle Handle;
   // On Mac, the inode number of the backing file is used as an id.
   typedef base::SharedMemoryId Id;
 #elif defined(OS_LINUX)
   typedef int Handle;  // These two ints are SysV IPC shared memory keys
   typedef int Id;
 #endif
 
   // Create a new TransportDIB
   //   size: the minimum size, in bytes
   //   epoch: Windows only: a global counter. See comment above.
   //   returns: NULL on failure
-  static TransportDIB* Create(size_t size, uint32 sequence_num);
+  static TransportDIB* Create(size_t size, uint32_t sequence_num);
 
   // Map the referenced transport DIB. Returns NULL on failure.
   static TransportDIB* Map(Handle transport_dib);
 
   // Return a pointer to the shared memory
   void* memory() const;
 
   // Return the maximum size of the shared memory. This is not the amount of
@@ -106,17 +106,17 @@ class TransportDIB {
   XID MapToX(Display* connection);
 #endif
 
  private:
   TransportDIB();
 #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_BSD)
   explicit TransportDIB(base::SharedMemoryHandle dib);
   base::SharedMemory shared_memory_;
-  uint32 sequence_num_;
+  uint32_t sequence_num_;
 #elif defined(OS_LINUX)
   int key_;  // SysV shared memory id
   void* address_;  // mapped address
   XID x_shm_;  // X id for the shared segment
   Display* display_;  // connection to the X server
 #endif
   size_t size_;  // length, in bytes
 };
--- a/ipc/chromium/src/chrome/common/transport_dib_linux.cc
+++ b/ipc/chromium/src/chrome/common/transport_dib_linux.cc
@@ -31,17 +31,17 @@ TransportDIB::~TransportDIB() {
 
   if (x_shm_) {
     DCHECK(display_);
     x11_util::DetachSharedMemory(display_, x_shm_);
   }
 }
 
 // static
-TransportDIB* TransportDIB::Create(size_t size, uint32 sequence_num) {
+TransportDIB* TransportDIB::Create(size_t size, uint32_t sequence_num) {
   // We use a mode of 0666 since the X server won't attach to memory which is
   // 0600 since it can't know if it (as a root process) is being asked to map
   // someone else's private shared memory region.
   const int shmkey = shmget(IPC_PRIVATE, size, 0666);
   if (shmkey == -1) {
     DLOG(ERROR) << "Failed to create SysV shared memory region"
                 << " errno:" << errno;
     return false;
--- a/ipc/chromium/src/chrome/common/transport_dib_mac.cc
+++ b/ipc/chromium/src/chrome/common/transport_dib_mac.cc
@@ -18,17 +18,17 @@ TransportDIB::TransportDIB(TransportDIB:
     : shared_memory_(dib, false /* read write */),
       size_(0) {
 }
 
 TransportDIB::~TransportDIB() {
 }
 
 // static
-TransportDIB* TransportDIB::Create(size_t size, uint32 sequence_num) {
+TransportDIB* TransportDIB::Create(size_t size, uint32_t sequence_num) {
   TransportDIB* dib = new TransportDIB;
   if (!dib->shared_memory_.Create("", false /* read write */,
                                   false /* do not open existing */, size)) {
     delete dib;
     return NULL;
   }
 
   dib->size_ = size;
--- a/ipc/chromium/src/chrome/common/transport_dib_win.cc
+++ b/ipc/chromium/src/chrome/common/transport_dib_win.cc
@@ -15,17 +15,17 @@ TransportDIB::TransportDIB() {
 TransportDIB::~TransportDIB() {
 }
 
 TransportDIB::TransportDIB(HANDLE handle)
     : shared_memory_(handle, false /* read write */) {
 }
 
 // static
-TransportDIB* TransportDIB::Create(size_t size, uint32 sequence_num) {
+TransportDIB* TransportDIB::Create(size_t size, uint32_t sequence_num) {
   size_t allocation_granularity = base::SysInfo::VMAllocationGranularity();
   size = size / allocation_granularity + 1;
   size = size * allocation_granularity;
 
   TransportDIB* dib = new TransportDIB;
 
   if (!dib->shared_memory_.Create("", false /* read write */,
                                   true /* open existing */, size)) {
--- a/ipc/chromium/src/chrome/common/visitedlink_common.cc
+++ b/ipc/chromium/src/chrome/common/visitedlink_common.cc
@@ -63,27 +63,27 @@ bool VisitedLinkCommon::IsVisited(Finger
 // where wchar_t is not 16 bits (Linux uses 32 bits, I think), this will not be
 // compatable. We should define explicitly what should happen here across
 // platforms, and convert if necessary (probably to UTF-16).
 
 // static
 VisitedLinkCommon::Fingerprint VisitedLinkCommon::ComputeURLFingerprint(
     const char* canonical_url,
     size_t url_len,
-    const uint8 salt[LINK_SALT_LENGTH]) {
+    const uint8_t salt[LINK_SALT_LENGTH]) {
   DCHECK(url_len > 0) << "Canonical URLs should not be empty";
 
   MD5Context ctx;
   MD5Init(&ctx);
   MD5Update(&ctx, salt, sizeof(salt));
   MD5Update(&ctx, canonical_url, url_len * sizeof(char));
 
   MD5Digest digest;
   MD5Final(&digest, &ctx);
 
   // This is the same as "return *(Fingerprint*)&digest.a;" but if we do that
   // direct cast the alignment could be wrong, and we can't access a 64-bit int
   // on arbitrary alignment on some processors. This reinterpret_casts it
   // down to a char array of the same size as fingerprint, and then does the
   // bit cast, which amounts to a memcpy. This does not handle endian issues.
-  return bit_cast<Fingerprint, uint8[8]>(
-      *reinterpret_cast<uint8(*)[8]>(&digest.a));
+  return bit_cast<Fingerprint, uint8_t[8]>(
+      *reinterpret_cast<uint8_t(*)[8]>(&digest.a));
 }
--- a/ipc/chromium/src/chrome/common/visitedlink_common.h
+++ b/ipc/chromium/src/chrome/common/visitedlink_common.h
@@ -38,20 +38,20 @@
 // we consider it visited. Otherwise, it is unvisited. Note that it is possible
 // to get collisions, which is the penalty for not storing all URL strings in
 // memory (which could get to be more than we want to have in memory). We use
 // a salt value for the links on one computer so that an attacker can not
 // manually create a link that causes a collision.
 class VisitedLinkCommon {
  public:
   // A number that identifies the URL.
-  typedef uint64 Fingerprint;
+  typedef uint64_t Fingerprint;
 
   // A hash value of a fingerprint
-  typedef int32 Hash;
+  typedef int32_t Hash;
 
   // A fingerprint or hash value that does not exist
   static const Fingerprint null_fingerprint_;
   static const Hash null_hash_;
 
   VisitedLinkCommon();
   virtual ~VisitedLinkCommon();
 
@@ -67,69 +67,69 @@ class VisitedLinkCommon {
   bool IsVisited(const char* canonical_url, size_t url_len) const;
   bool IsVisited(const GURL& url) const {
     return IsVisited(url.spec().data(), url.spec().size());
   }
   bool IsVisited(Fingerprint fingerprint) const;
 
 #ifdef UNIT_TEST
   // Returns statistics about DB usage
-  void GetUsageStatistics(int32* table_size,
+  void GetUsageStatistics(int32_t* table_size,
                           VisitedLinkCommon::Fingerprint** fingerprints) {
     *table_size = table_length_;
     *fingerprints = hash_table_;
   }
 #endif
 
  protected:
   // This structure is at the beginning of the shared memory so that the slaves
   // can get stats on the table
   struct SharedHeader {
     // see goes into table_length_
-    uint32 length;
+    uint32_t length;
 
     // goes into salt_
-    uint8 salt[LINK_SALT_LENGTH];
+    uint8_t salt[LINK_SALT_LENGTH];
   };
 
   // Returns the fingerprint at the given index into the URL table. This
   // function should be called instead of accessing the table directly to
   // contain endian issues.
-  Fingerprint FingerprintAt(int32 table_offset) const {
+  Fingerprint FingerprintAt(int32_t table_offset) const {
     if (!hash_table_)
       return null_fingerprint_;
     return hash_table_[table_offset];
   }
 
   // Computes the fingerprint of the given canonical URL. It is static so the
   // same algorithm can be re-used by the table rebuilder, so you will have to
   // pass the salt as a parameter. See the non-static version above if you
   // want to use the current class' salt.
   static Fingerprint ComputeURLFingerprint(const char* canonical_url,
                                            size_t url_len,
-                                           const uint8 salt[LINK_SALT_LENGTH]);
+                                           const uint8_t salt[LINK_SALT_LENGTH]);
 
   // Computes the hash value of the given fingerprint, this is used as a lookup
   // into the hashtable.
-  static Hash HashFingerprint(Fingerprint fingerprint, int32 table_length) {
+  static Hash HashFingerprint(Fingerprint fingerprint, int32_t table_length) {
     if (table_length == 0)
       return null_hash_;
     return static_cast<Hash>(fingerprint % table_length);
   }
   // Uses the current hashtable.
   Hash HashFingerprint(Fingerprint fingerprint) const {
     return HashFingerprint(fingerprint, table_length_);
   }
 
   // pointer to the first item
   VisitedLinkCommon::Fingerprint* hash_table_;
 
   // the number of items in the hash table
-  int32 table_length_;
+  int32_t table_length_;
 
   // salt used for each URL when computing the fingerprint
-  uint8 salt_[LINK_SALT_LENGTH];
+  uint8_t salt_[LINK_SALT_LENGTH];
 
  private:
   DISALLOW_EVIL_CONSTRUCTORS(VisitedLinkCommon);
 };
 
 #endif // WIN_COMMON_VISITEDLINK_COMMON_H__
--- a/ipc/chromium/src/testing/gtest/include/gtest/internal/gtest-port.h
+++ b/ipc/chromium/src/testing/gtest/include/gtest/internal/gtest-port.h
@@ -854,17 +854,17 @@ class TypeWithSize {
 
 // The specialization for size 4.
 template <>
 class TypeWithSize<4> {
  public:
   // unsigned int has size 4 in both gcc and MSVC.
   //
   // As base/basictypes.h doesn't compile on Windows, we cannot use
-  // uint32, uint64, and etc here.
+  // uint32_t, uint64_t, and etc here.
   typedef int Int;
   typedef unsigned int UInt;
 };
 
 // The specialization for size 8.
 template <>
 class TypeWithSize<8> {
  public:
--- a/ipc/glue/AsyncChannel.cpp
+++ b/ipc/glue/AsyncChannel.cpp
@@ -469,17 +469,17 @@ AsyncChannel::OnDispatchMessage(const Me
 
     // it's OK to dispatch messages if the channel is closed/error'd,
     // since we don't have a reply to send back
 
     (void)MaybeHandleError(mListener->OnMessageReceived(msg), "AsyncChannel");
 }
 
 bool
-AsyncChannel::OnSpecialMessage(uint16 id, const Message& msg)
+AsyncChannel::OnSpecialMessage(uint16_t id, const Message& msg)
 {
     return false;
 }
 
 void
 AsyncChannel::SendSpecialMessage(Message* msg) const
 {
     AssertWorkerThread();
@@ -641,17 +641,17 @@ AsyncChannel::ReportConnectionError(cons
     }
 
     PrintErrorMessage(mChild, channelName, errorMsg);
 
     mListener->OnProcessingError(MsgDropped);
 }
 
 void
-AsyncChannel::DispatchOnChannelConnected(int32 peer_pid)
+AsyncChannel::DispatchOnChannelConnected(int32_t peer_pid)
 {
     AssertWorkerThread();
     if (mListener)
         mListener->OnChannelConnected(peer_pid);
 }
 
 //
 // The methods below run in the context of the IO thread
@@ -717,17 +717,17 @@ AsyncChannel::ProcessLink::OnTakeConnect
     // Dispatch whatever messages the previous listener had queued up.
     while (!pending.empty()) {
         OnMessageReceived(pending.front());
         pending.pop();
     }
 }
 
 void
-AsyncChannel::ProcessLink::OnChannelConnected(int32 peer_pid)
+AsyncChannel::ProcessLink::OnChannelConnected(int32_t peer_pid)
 {
     AssertIOThread();
 
     {
         MonitorAutoLock lock(*mChan->mMonitor);
         mChan->mChannelState = ChannelConnected;
         mChan->mMonitor->Notify();
     }
--- a/ipc/glue/AsyncChannel.h
+++ b/ipc/glue/AsyncChannel.h
@@ -66,17 +66,17 @@ public:
     {
     public:
         virtual ~AsyncListener() { }
 
         virtual void OnChannelClose() = 0;
         virtual void OnChannelError() = 0;
         virtual Result OnMessageReceived(const Message& aMessage) = 0;
         virtual void OnProcessingError(Result aError) = 0;
-        virtual void OnChannelConnected(int32 peer_pid) {};
+        virtual void OnChannelConnected(int32_t peer_pid) {};
     };
 
     enum Side { Parent, Child, Unknown };
 
 public:
     //
     // These methods are called on the "worker" thread
     //
@@ -110,17 +110,17 @@ public:
     // Asynchronously send a message to the other side of the channel
     virtual bool Send(Message* msg);
 
     // Asynchronously deliver a message back to this side of the
     // channel
     virtual bool Echo(Message* msg);
 
     // Send OnChannelConnected notification to listeners.
-    void DispatchOnChannelConnected(int32 peer_pid);
+    void DispatchOnChannelConnected(int32_t peer_pid);
 
     //
     // Each AsyncChannel is associated with either a ProcessLink or a
     // ThreadLink via the field mLink.  The type of link is determined
     // by whether this AsyncChannel is communicating with another
     // process or another thread.  In the former case, file
     // descriptors or a socket are used via the I/O queue.  In the
     // latter case, messages are enqueued directly onto the target
@@ -164,17 +164,17 @@ public:
         virtual ~ProcessLink();
         void Open(Transport* aTransport, MessageLoop *aIOLoop, Side aSide);
         
         // Run on the I/O thread, only when using inter-process link.
         // These methods acquire the monitor and forward to the
         // similarly named methods in AsyncChannel below
         // (OnMessageReceivedFromLink(), etc)
         virtual void OnMessageReceived(const Message& msg) MOZ_OVERRIDE;
-        virtual void OnChannelConnected(int32 peer_pid) MOZ_OVERRIDE;
+        virtual void OnChannelConnected(int32_t peer_pid) MOZ_OVERRIDE;
         virtual void OnChannelError() MOZ_OVERRIDE;
 
         virtual void EchoMessage(Message *msg) MOZ_OVERRIDE;
         virtual void SendMessage(Message *msg) MOZ_OVERRIDE;
         virtual void SendClose() MOZ_OVERRIDE;
     };
     
     class ThreadLink : public Link {
@@ -228,17 +228,17 @@ protected:
     // In the case of a ThreadLink, it is acquired by the other actor, 
     // which then invokes these methods directly.
     virtual void OnMessageReceivedFromLink(const Message& msg);
     virtual void OnChannelErrorFromLink();
     void PostErrorNotifyTask();
 
     // Run on the worker thread
     void OnDispatchMessage(const Message& aMsg);
-    virtual bool OnSpecialMessage(uint16 id, const Message& msg);
+    virtual bool OnSpecialMessage(uint16_t id, const Message& msg);
     void SendSpecialMessage(Message* msg) const;
 
     // Tell the IO thread to close the channel and wait for it to ACK.
     void SynchronouslyClose();
 
     bool MaybeHandleError(Result code, const char* channelName);
     void ReportConnectionError(const char* channelName) const;
 
--- a/ipc/glue/GeckoChildProcessHost.cpp
+++ b/ipc/glue/GeckoChildProcessHost.cpp
@@ -164,17 +164,17 @@ public:
   {
     ::CFRelease(mObject);
   }
 private:
   CFTypeRef mObject;
 };
 #endif
 
-nsresult GeckoChildProcessHost::GetArchitecturesForBinary(const char *path, uint32 *result)
+nsresult GeckoChildProcessHost::GetArchitecturesForBinary(const char *path, uint32_t *result)
 {
   *result = 0;
 
 #ifdef MOZ_WIDGET_COCOA
   CFURLRef url = ::CFURLCreateFromFileSystemRepresentation(kCFAllocatorDefault,
                                                            (const UInt8*)path,
                                                            strlen(path),
                                                            false);
@@ -212,22 +212,22 @@ nsresult GeckoChildProcessHost::GetArchi
   }
 
   return (*result ? NS_OK : NS_ERROR_FAILURE);
 #else
   return NS_ERROR_NOT_IMPLEMENTED;
 #endif
 }
 
-uint32 GeckoChildProcessHost::GetSupportedArchitecturesForProcessType(GeckoProcessType type)
+uint32_t GeckoChildProcessHost::GetSupportedArchitecturesForProcessType(GeckoProcessType type)
 {
 #ifdef MOZ_WIDGET_COCOA
   if (type == GeckoProcessType_Plugin) {
     // Cache this, it shouldn't ever change.
-    static uint32 pluginContainerArchs = 0;
+    static uint32_t pluginContainerArchs = 0;
     if (pluginContainerArchs == 0) {
       FilePath exePath;
       GetPathToBinary(exePath);
       nsresult rv = GetArchitecturesForBinary(exePath.value().c_str(), &pluginContainerArchs);
       NS_ASSERTION(NS_SUCCEEDED(rv) && pluginContainerArchs != 0, "Getting architecture of plugin container failed!");
       if (NS_FAILED(rv) || pluginContainerArchs == 0) {
         pluginContainerArchs = base::GetCurrentProcessArchitecture();
       }
@@ -739,17 +739,17 @@ GeckoChildProcessHost::OpenPrivilegedHan
     return;
   }
   if (!base::OpenPrivilegedProcessHandle(aPid, &mChildProcessHandle)) {
     NS_RUNTIMEABORT("can't open handle to child process");
   }
 }
 
 void
-GeckoChildProcessHost::OnChannelConnected(int32 peer_pid)
+GeckoChildProcessHost::OnChannelConnected(int32_t peer_pid)
 {
   OpenPrivilegedHandle(peer_pid);
   {
     MonitorAutoLock lock(mMonitor);
     mProcessState = PROCESS_CONNECTED;
     lock.Notify();
   }
 }
--- a/ipc/glue/GeckoChildProcessHost.h
+++ b/ipc/glue/GeckoChildProcessHost.h
@@ -29,19 +29,19 @@ public:
   typedef base::ChildPrivileges ChildPrivileges;
   typedef base::ProcessHandle ProcessHandle;
 
   GeckoChildProcessHost(GeckoProcessType aProcessType,
                         ChildPrivileges aPrivileges=base::PRIVILEGES_DEFAULT);
 
   ~GeckoChildProcessHost();
 
-  static nsresult GetArchitecturesForBinary(const char *path, uint32 *result);
+  static nsresult GetArchitecturesForBinary(const char *path, uint32_t *result);
 
-  static uint32 GetSupportedArchitecturesForProcessType(GeckoProcessType type);
+  static uint32_t GetSupportedArchitecturesForProcessType(GeckoProcessType type);
 
   // Block until the IPC channel for our subprocess is initialized,
   // but no longer.  The child process may or may not have been
   // created when this method returns.
   bool AsyncLaunch(StringVector aExtraOpts=StringVector());
 
   // Block until the IPC channel for our subprocess is initialized and
   // the OS process is created.  The subprocess may or may not have
@@ -56,23 +56,23 @@ public:
   // we return.  But we don't know if dynamic linking succeeded on
   // either platform.
   bool LaunchAndWaitForProcessHandle(StringVector aExtraOpts=StringVector());
 
   // Block until the child process has been created and it connects to
   // the IPC channel, meaning it's fully initialized.  (Or until an
   // error occurs.)
   bool SyncLaunch(StringVector aExtraOpts=StringVector(),
-                  int32 timeoutMs=0,
+                  int32_t timeoutMs=0,
                   base::ProcessArchitecture arch=base::GetCurrentProcessArchitecture());
 
   bool PerformAsyncLaunch(StringVector aExtraOpts=StringVector(),
                           base::ProcessArchitecture arch=base::GetCurrentProcessArchitecture());
 
-  virtual void OnChannelConnected(int32 peer_pid);
+  virtual void OnChannelConnected(int32_t peer_pid);
   virtual void OnMessageReceived(const IPC::Message& aMsg);
   virtual void OnChannelError();
   virtual void GetQueuedMessages(std::queue<IPC::Message>& queue);
 
   void InitializeChannel();
 
   virtual bool CanShutdown() { return true; }
 
--- a/ipc/glue/IPCMessageUtils.h
+++ b/ipc/glue/IPCMessageUtils.h
@@ -128,21 +128,21 @@ struct EnumSerializer {
   typedef E paramType;
 
   static bool IsLegalValue(const paramType &aValue) {
     return smallestLegal <= aValue && aValue < highBound;
   }
 
   static void Write(Message* aMsg, const paramType& aValue) {
     MOZ_ASSERT(IsLegalValue(aValue));
-    WriteParam(aMsg, (int32)aValue);
+    WriteParam(aMsg, (int32_t)aValue);
   }
 
   static bool Read(const Message* aMsg, void** aIter, paramType* aResult) {
-    int32 value;
+    int32_t value;
     if(!ReadParam(aMsg, aIter, &value) ||
        !IsLegalValue(paramType(value))) {
       return false;
     }
     *aResult = paramType(value);
     return true;
   }
 };
--- a/ipc/glue/ProtocolUtils.cpp
+++ b/ipc/glue/ProtocolUtils.cpp
@@ -24,28 +24,28 @@ public:
                 ProcessId aOtherProcess,
                 ProtocolId aProtocol)
     : IPC::Message(MSG_ROUTING_CONTROL, // these only go to top-level actors
                    CHANNEL_OPENED_MESSAGE_TYPE,
                    PRIORITY_NORMAL)
   {
     IPC::WriteParam(this, aDescriptor);
     IPC::WriteParam(this, aOtherProcess);
-    IPC::WriteParam(this, static_cast<uint32>(aProtocol));
+    IPC::WriteParam(this, static_cast<uint32_t>(aProtocol));
   }
 
   static bool Read(const IPC::Message& aMsg,
                    TransportDescriptor* aDescriptor,
                    ProcessId* aOtherProcess,
                    ProtocolId* aProtocol)
   {
     void* iter = nullptr;
     if (!IPC::ReadParam(&aMsg, &iter, aDescriptor) ||
         !IPC::ReadParam(&aMsg, &iter, aOtherProcess) ||
-        !IPC::ReadParam(&aMsg, &iter, reinterpret_cast<uint32*>(aProtocol))) {
+        !IPC::ReadParam(&aMsg, &iter, reinterpret_cast<uint32_t*>(aProtocol))) {
       return false;
     }
     aMsg.EndRead(iter);
     return true;
   }
 };
 
 bool
--- a/ipc/glue/ProtocolUtils.h
+++ b/ipc/glue/ProtocolUtils.h
@@ -55,49 +55,49 @@ struct ActorHandle
 // transition.  Triggers are normalized across parent+child to Send
 // and Recv (instead of child-in, child-out, parent-in, parent-out) so
 // that they can share the same state machine implementation.  To
 // further normalize, |Send| is used for 'call', |Recv| for 'answer'.
 struct Trigger
 {
     enum Action { Send, Recv };
 
-    Trigger(Action action, int32 msg) :
+    Trigger(Action action, int32_t msg) :
         mAction(action),
         mMsg(msg)
     {}
 
     Action mAction;
-    int32 mMsg;
+    int32_t mMsg;
 };
 
 template<class ListenerT>
 class /*NS_INTERFACE_CLASS*/ IProtocolManager
 {
 public:
     enum ActorDestroyReason {
         FailedConstructor,
         Deletion,
         AncestorDeletion,
         NormalShutdown,
         AbnormalShutdown
     };
 
     typedef base::ProcessHandle ProcessHandle;
 
-    virtual int32 Register(ListenerT*) = 0;
-    virtual int32 RegisterID(ListenerT*, int32) = 0;
-    virtual ListenerT* Lookup(int32) = 0;
-    virtual void Unregister(int32) = 0;
-    virtual void RemoveManagee(int32, ListenerT*) = 0;
+    virtual int32_t Register(ListenerT*) = 0;
+    virtual int32_t RegisterID(ListenerT*, int32_t) = 0;
+    virtual ListenerT* Lookup(int32_t) = 0;
+    virtual void Unregister(int32_t) = 0;
+    virtual void RemoveManagee(int32_t, ListenerT*) = 0;
 
     virtual Shmem::SharedMemory* CreateSharedMemory(
-        size_t, SharedMemory::SharedMemoryType, bool, int32*) = 0;
-    virtual bool AdoptSharedMemory(Shmem::SharedMemory*, int32*) = 0;
-    virtual Shmem::SharedMemory* LookupSharedMemory(int32) = 0;
+        size_t, SharedMemory::SharedMemoryType, bool, int32_t*) = 0;
+    virtual bool AdoptSharedMemory(Shmem::SharedMemory*, int32_t*) = 0;
+    virtual Shmem::SharedMemory* LookupSharedMemory(int32_t) = 0;
     virtual bool IsTrackingSharedMemory(Shmem::SharedMemory*) = 0;
     virtual bool DestroySharedMemory(Shmem&) = 0;
 
     // XXX odd ducks, acknowledged
     virtual ProcessHandle OtherProcess() const = 0;
     virtual AsyncChannel* GetIPCChannel() = 0;
 };
 
--- a/ipc/glue/RPCChannel.cpp
+++ b/ipc/glue/RPCChannel.cpp
@@ -525,17 +525,17 @@ RPCChannel::UnblockChild()
         NS_RUNTIMEABORT("child tried to unblock parent");
 
     MonitorAutoLock lock(*mMonitor);
     SendSpecialMessage(new UnblockChildMessage());
     return true;
 }
 
 bool
-RPCChannel::OnSpecialMessage(uint16 id, const Message& msg)
+RPCChannel::OnSpecialMessage(uint16_t id, const Message& msg)
 {
     AssertWorkerThread();
 
     switch (id) {
     case BLOCK_CHILD_MESSAGE_TYPE:
         BlockOnParent();
         return true;
 
@@ -661,17 +661,17 @@ RPCChannel::DumpRPCStack(const char* con
 {
     NS_WARN_IF_FALSE(MessageLoop::current() != mWorkerLoop,
                      "The worker thread had better be paused in a debugger!");
 
     printf_stderr("%sRPCChannel 'backtrace':\n", pfx);
 
     // print a python-style backtrace, first frame to last
     for (uint32_t i = 0; i < mCxxStackFrames.size(); ++i) {
-        int32 id;
+        int32_t id;
         const char* dir, *sems, *name;
         mCxxStackFrames[i].Describe(&id, &dir, &sems, &name);
 
         printf_stderr("%s[(%u) %s %s %s(actor=%d) ]\n", pfx,
                       i, dir, sems, name, id);
     }
 }
 
--- a/ipc/glue/RPCChannel.h
+++ b/ipc/glue/RPCChannel.h
@@ -46,17 +46,17 @@ public:
         virtual void OnChannelError() = 0;
         virtual Result OnMessageReceived(const Message& aMessage) = 0;
         virtual void OnProcessingError(Result aError) = 0;
         virtual bool OnReplyTimeout() = 0;
         virtual Result OnMessageReceived(const Message& aMessage,
                                          Message*& aReply) = 0;
         virtual Result OnCallReceived(const Message& aMessage,
                                       Message*& aReply) = 0;
-        virtual void OnChannelConnected(int32 peer_pid) {};
+        virtual void OnChannelConnected(int32_t peer_pid) {};
 
         virtual void OnEnteredCxxStack()
         {
             NS_RUNTIMEABORT("default impl shouldn't be invoked");
         }
 
         virtual void OnExitedCxxStack()
         {
@@ -118,17 +118,17 @@ public:
     // Return true iff successful.
     bool UnblockChild();
 
     // Return true iff this has code on the C++ stack.
     bool IsOnCxxStack() const {
         return !mCxxStackFrames.empty();
     }
 
-    virtual bool OnSpecialMessage(uint16 id, const Message& msg) MOZ_OVERRIDE;
+    virtual bool OnSpecialMessage(uint16_t id, const Message& msg) MOZ_OVERRIDE;
 
 
     /**
      * If there is a pending RPC message, process all pending messages.
      *
      * @note This method is used on Windows when we detect that an outbound
      * OLE RPC call is being made to unblock the parent.
      */
@@ -219,17 +219,17 @@ private:
             return mMsg->is_rpc() && IN_MESSAGE == mDirection;
         }
 
         bool IsRPCOutcall() const
         {
             return mMsg->is_rpc() && OUT_MESSAGE == mDirection;
         }
 
-        void Describe(int32* id, const char** dir, const char** sems,
+        void Describe(int32_t* id, const char** dir, const char** sems,
                       const char** name) const
         {
             *id = mMsg->routing_id();
             *dir = (IN_MESSAGE == mDirection) ? "in" : "out";
             *sems = mMsg->is_rpc() ? "rpc" : mMsg->is_sync() ? "sync" : "async";
             *name = mMsg->name();
         }
 
--- a/ipc/glue/Shmem.cpp
+++ b/ipc/glue/Shmem.cpp
@@ -19,66 +19,66 @@ namespace mozilla {
 namespace ipc {
 
 class ShmemCreated : public IPC::Message
 {
 private:
   typedef Shmem::id_t id_t;
 
 public:
-  ShmemCreated(int32 routingId,
+  ShmemCreated(int32_t routingId,
                const id_t& aIPDLId,
                const size_t& aSize,
                const SharedMemoryBasic::Handle& aHandle) :
     IPC::Message(routingId, SHMEM_CREATED_MESSAGE_TYPE, PRIORITY_NORMAL)
   {
     IPC::WriteParam(this, aIPDLId);
     IPC::WriteParam(this, aSize);
-    IPC::WriteParam(this, int32(SharedMemory::TYPE_BASIC)),
+    IPC::WriteParam(this, int32_t(SharedMemory::TYPE_BASIC)),
     IPC::WriteParam(this, aHandle);
   }
 
   // Instead of a single Read() function, we have ReadInfo() and
   // ReadHandle().  The reason is that the handle type is specific to
   // the shmem type.  These functions should only be called in the
   // order ReadInfo(); ReadHandle();, and only once each.
 
   static bool
   ReadInfo(const Message* msg, void** iter,
            id_t* aIPDLId,
            size_t* aSize,
            SharedMemory::SharedMemoryType* aType)
   {
     if (!IPC::ReadParam(msg, iter, aIPDLId) ||
         !IPC::ReadParam(msg, iter, aSize) ||
-        !IPC::ReadParam(msg, iter, reinterpret_cast<int32*>(aType)))
+        !IPC::ReadParam(msg, iter, reinterpret_cast<int32_t*>(aType)))
       return false;
     return true;
   }
 
   static bool
   ReadHandle(const Message* msg, void** iter,
              SharedMemoryBasic::Handle* aHandle)
   {
     if (!IPC::ReadParam(msg, iter, aHandle))
       return false;
     msg->EndRead(*iter);
     return true;
   }
 
 #ifdef MOZ_HAVE_SHAREDMEMORYSYSV
-  ShmemCreated(int32 routingId,
+  ShmemCreated(int32_t routingId,
                const id_t& aIPDLId,
                const size_t& aSize,
                const SharedMemorySysV::Handle& aHandle) :
     IPC::Message(routingId, SHMEM_CREATED_MESSAGE_TYPE, PRIORITY_NORMAL)
   {
     IPC::WriteParam(this, aIPDLId);
     IPC::WriteParam(this, aSize);
-    IPC::WriteParam(this, int32(SharedMemory::TYPE_SYSV)),
+    IPC::WriteParam(this, int32_t(SharedMemory::TYPE_SYSV)),
     IPC::WriteParam(this, aHandle);
   }
 
   static bool
   ReadHandle(const Message* msg, void** iter,
              SharedMemorySysV::Handle* aHandle)
   {
     if (!IPC::ReadParam(msg, iter, aHandle))
@@ -96,17 +96,17 @@ public:
 };
 
 class ShmemDestroyed : public IPC::Message
 {
 private:
   typedef Shmem::id_t id_t;
 
 public:
-  ShmemDestroyed(int32 routingId,
+  ShmemDestroyed(int32_t routingId,
                  const id_t& aIPDLId) :
     IPC::Message(routingId, SHMEM_DESTROYED_MESSAGE_TYPE, PRIORITY_NORMAL)
   {
     IPC::WriteParam(this, aIPDLId);
   }
 };
 
 
@@ -171,18 +171,18 @@ static const char sMagic[] =
     "This little piggy has roast beef,\n"
     "This little piggy had none.\n"
     "And this little piggy cried \"Wee! Wee! Wee!\" all the way home";
 
 
 struct Header {
   // Don't use size_t or bool here because their size depends on the
   // architecture.
-  uint32 mSize;
-  uint32 mUnsafe;
+  uint32_t mSize;
+  uint32_t mUnsafe;
   char mMagic[sizeof(sMagic)];
 };
 
 static void
 GetSections(Shmem::SharedMemory* aSegment,
             Header** aHeader,
             char** aFrontSentinel,
             char** aData,
@@ -385,17 +385,17 @@ Shmem::Alloc(IHadBetterBeIPDLCodeCalling
   // initialize the segment with Shmem-internal information
 
   // NB: this can't be a static assert because technically pageSize
   // isn't known at compile time, event though in practice it's always
   // going to be 4KiB
   NS_ABORT_IF_FALSE(sizeof(Header) <= pageSize,
                     "Shmem::Header has gotten too big");
   memcpy(header->mMagic, sMagic, sizeof(sMagic));
-  header->mSize = static_cast<uint32>(aNBytes);
+  header->mSize = static_cast<uint32_t>(aNBytes);
   header->mUnsafe = aUnsafe;
 
   if (aProtect)
     Protect(segment);
 
   return segment;
 }
 
@@ -488,31 +488,31 @@ Shmem::Alloc(IHadBetterBeIPDLCodeCalling
              size_t aNBytes, 
              SharedMemoryType aType,
              bool /*unused*/,
              bool /*unused*/)
 {
   SharedMemory *segment = nullptr;
 
   if (aType == SharedMemory::TYPE_BASIC)
-    segment = CreateSegment(SharedMemory::PageAlignedSize(aNBytes + sizeof(uint32)),
+    segment = CreateSegment(SharedMemory::PageAlignedSize(aNBytes + sizeof(uint32_t)),
                             SharedMemoryBasic::NULLHandle());
 #ifdef MOZ_HAVE_SHAREDMEMORYSYSV
   else if (aType == SharedMemory::TYPE_SYSV)
-    segment = CreateSegment(SharedMemory::PageAlignedSize(aNBytes + sizeof(uint32)),
+    segment = CreateSegment(SharedMemory::PageAlignedSize(aNBytes + sizeof(uint32_t)),
                             SharedMemorySysV::NULLHandle());
 #endif
   else
     // Unhandled!!
     NS_ABORT();
 
   if (!segment)
     return 0;
 
-  *PtrToSize(segment) = static_cast<uint32>(aNBytes);
+  *PtrToSize(segment) = static_cast<uint32_t>(aNBytes);
 
   return segment;
 }
 
 // static
 Shmem::SharedMemory*
 Shmem::OpenExisting(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
                     const IPC::Message& aDescriptor,
@@ -524,17 +524,17 @@ Shmem::OpenExisting(IHadBetterBeIPDLCode
 
   SharedMemory::SharedMemoryType type;
   void* iter = 0;
   size_t size;
   if (!ShmemCreated::ReadInfo(&aDescriptor, &iter, aId, &size, &type))
     return 0;
 
   SharedMemory* segment = 0;
-  size_t segmentSize = SharedMemory::PageAlignedSize(size + sizeof(uint32));
+  size_t segmentSize = SharedMemory::PageAlignedSize(size + sizeof(uint32_t));
 
   if (SharedMemory::TYPE_BASIC == type) {
     SharedMemoryBasic::Handle handle;
     if (!ShmemCreated::ReadHandle(&aDescriptor, &iter, &handle))
       return 0;
 
     if (!SharedMemoryBasic::IsHandleValid(handle))
       NS_RUNTIMEABORT("trying to open invalid handle");
@@ -591,17 +591,17 @@ Shmem::GetSysVID() const
   NS_RUNTIMEABORT("Can't call GetSysVID() with no support for SysV shared memory!");
   return -1;                    // not reached
 #endif
 }
 
 IPC::Message*
 Shmem::ShareTo(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
                base::ProcessHandle aProcess,
-               int32 routingId)
+               int32_t routingId)
 {
   AssertInvariants();
 
   if (SharedMemory::TYPE_BASIC == mSegment->Type()) {
     SharedMemoryBasic* seg = static_cast<SharedMemoryBasic*>(mSegment);
     SharedMemoryBasic::Handle handle;
     if (!seg->ShareToProcess(aProcess, &handle))
       return 0;
@@ -619,16 +619,16 @@ Shmem::ShareTo(IHadBetterBeIPDLCodeCalli
   }
 
   return 0;
 }
 
 IPC::Message*
 Shmem::UnshareFrom(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
                    base::ProcessHandle aProcess,
-                   int32 routingId)
+                   int32_t routingId)
 {
   AssertInvariants();
   return new ShmemDestroyed(routingId, mId);
 }
 
 } // namespace ipc
 } // namespace mozilla
--- a/ipc/glue/Shmem.h
+++ b/ipc/glue/Shmem.h
@@ -56,17 +56,17 @@
 namespace mozilla {
 namespace ipc {
 
 class Shmem MOZ_FINAL
 {
   friend struct IPC::ParamTraits<mozilla::ipc::Shmem>;
 
 public:
-  typedef int32 id_t;
+  typedef int32_t id_t;
   // Low-level wrapper around platform shmem primitives.
   typedef mozilla::ipc::SharedMemory SharedMemory;
   typedef SharedMemory::SharedMemoryType SharedMemoryType;
   struct IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead {};
 
   Shmem() :
     mSegment(0),
     mData(0),
@@ -202,26 +202,26 @@ public:
 
   // Prepare this to be shared with |aProcess|.  Return an IPC message
   // that contains enough information for the other process to map
   // this segment in OpenExisting() below.  Return a new message if
   // successful (owned by the caller), NULL if not.
   IPC::Message*
   ShareTo(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
           base::ProcessHandle aProcess,
-          int32 routingId);
+          int32_t routingId);
 
   // Stop sharing this with |aProcess|.  Return an IPC message that
   // contains enough information for the other process to unmap this
   // segment.  Return a new message if successful (owned by the
   // caller), NULL if not.
   IPC::Message*
   UnshareFrom(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
               base::ProcessHandle aProcess,
-              int32 routingId);
+              int32_t routingId);
 
   // Return a SharedMemory instance in this process using the
   // descriptor shared to us by the process that created the
   // underlying OS shmem resource.  The contents of the descriptor
   // depend on the type of SharedMemory that was passed to us.
   static SharedMemory*
   OpenExisting(IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead,
                const IPC::Message& aDescriptor,
@@ -239,22 +239,22 @@ private:
     if (0 != (mSize % sizeof(T)))
       NS_RUNTIMEABORT("shmem is not T-aligned");
   }
 
 #if !defined(DEBUG)
   void AssertInvariants() const
   { }
 
-  static uint32*
+  static uint32_t*
   PtrToSize(SharedMemory* aSegment)
   {
     char* endOfSegment =
       reinterpret_cast<char*>(aSegment->memory()) + aSegment->Size();
-    return reinterpret_cast<uint32*>(endOfSegment - sizeof(uint32));
+    return reinterpret_cast<uint32_t*>(endOfSegment - sizeof(uint32_t));
   }
 
 #else
   void AssertInvariants() const;
 #endif
 
   SharedMemory* mSegment;
   void* mData;
--- a/ipc/glue/SyncChannel.cpp
+++ b/ipc/glue/SyncChannel.cpp
@@ -17,17 +17,17 @@ struct RunnableMethodTraits<mozilla::ipc
 {
     static void RetainCallee(mozilla::ipc::SyncChannel* obj) { }
     static void ReleaseCallee(mozilla::ipc::SyncChannel* obj) { }
 };
 
 namespace mozilla {
 namespace ipc {
 
-const int32 SyncChannel::kNoTimeout = PR_INT32_MIN;
+const int32_t SyncChannel::kNoTimeout = PR_INT32_MIN;
 
 SyncChannel::SyncChannel(SyncListener* aListener)
   : AsyncChannel(aListener)
   , mPendingReply(0)
   , mProcessingSyncMessage(false)
   , mNextSeqno(0)
   , mInTimeoutSecondHalf(false)
   , mTimeoutMs(kNoTimeout)
@@ -83,17 +83,17 @@ SyncChannel::Send(Message* _msg, Message
     MonitorAutoLock lock(*mMonitor);
 
     if (!Connected()) {
         ReportConnectionError("SyncChannel");
         return false;
     }
 
     mPendingReply = msg->type() + 1;
-    int32 msgSeqno = msg->seqno();
+    int32_t msgSeqno = msg->seqno();
     mLink->SendMessage(msg.forget());
 
     while (1) {
         bool maybeTimedOut = !SyncChannel::WaitForNotify();
 
         if (EventOccurred())
             break;
 
--- a/ipc/glue/SyncChannel.h
+++ b/ipc/glue/SyncChannel.h
@@ -15,51 +15,51 @@ namespace ipc {
 //-----------------------------------------------------------------------------
 
 class SyncChannel : public AsyncChannel
 {
 protected:
     typedef IPC::Message::msgid_t msgid_t;
 
 public:
-    static const int32 kNoTimeout;
+    static const int32_t kNoTimeout;
 
     class /*NS_INTERFACE_CLASS*/ SyncListener : 
         public AsyncChannel::AsyncListener
     {
     public:
         virtual ~SyncListener() { }
 
         virtual void OnChannelClose() = 0;
         virtual void OnChannelError() = 0;
         virtual Result OnMessageReceived(const Message& aMessage) = 0;
         virtual void OnProcessingError(Result aError) = 0;
         virtual bool OnReplyTimeout() = 0;
         virtual Result OnMessageReceived(const Message& aMessage,
                                          Message*& aReply) = 0;
-        virtual void OnChannelConnected(int32 peer_pid) {};
+        virtual void OnChannelConnected(int32_t peer_pid) {};
     };
 
     SyncChannel(SyncListener* aListener);
     virtual ~SyncChannel();
 
     virtual bool Send(Message* msg) MOZ_OVERRIDE {
         return AsyncChannel::Send(msg);
     }
 
     // Synchronously send |msg| (i.e., wait for |reply|)
     virtual bool Send(Message* msg, Message* reply);
 
     // Set channel timeout value. Since this is broken up into
     // two period, the minimum timeout value is 2ms.
-    void SetReplyTimeoutMs(int32 aTimeoutMs) {
+    void SetReplyTimeoutMs(int32_t aTimeoutMs) {
         AssertWorkerThread();
         mTimeoutMs = (aTimeoutMs <= 0) ? kNoTimeout :
           // timeouts are broken up into two periods
-          (int32)ceil((double)aTimeoutMs/2.0);
+          (int32_t)ceil((double)aTimeoutMs/2.0);
     }
 
     static bool IsPumpingMessages() {
         return sIsPumpingMessages;
     }
     static void SetIsPumpingMessages(bool aIsPumping) {
         sIsPumpingMessages = aIsPumping;
     }
@@ -137,37 +137,37 @@ protected:
     void NotifyWorkerThread();
 
     // On both
     bool AwaitingSyncReply() const {
         mMonitor->AssertCurrentThreadOwns();
         return mPendingReply != 0;
     }
 
-    int32 NextSeqno() {
+    int32_t NextSeqno() {
         AssertWorkerThread();
         return mChild ? --mNextSeqno : ++mNextSeqno;
     }
 
     msgid_t mPendingReply;
     bool mProcessingSyncMessage;
     Message mRecvd;
     // This is only accessed from the worker thread; seqno's are
     // completely opaque to the IO thread.
-    int32 mNextSeqno;
+    int32_t mNextSeqno;
 
     static bool sIsPumpingMessages;
 
     // Timeout periods are broken up in two to prevent system suspension from
     // triggering an abort. This method (called by WaitForNotify with a 'did
     // timeout' flag) decides if we should wait again for half of mTimeoutMs
     // or give up.
     bool WaitResponse(bool aWaitTimedOut);
     bool mInTimeoutSecondHalf;
-    int32 mTimeoutMs;
+    int32_t mTimeoutMs;
 
 #ifdef OS_WIN
     HANDLE mEvent;
 #endif
 
 private:
     bool EventOccurred();
 };
--- a/ipc/glue/WindowsMessageLoop.cpp
+++ b/ipc/glue/WindowsMessageLoop.cpp
@@ -534,17 +534,17 @@ Init()
 struct TimeoutData
 {
   DWORD startTicks;
   DWORD targetTicks;
 };
 
 void
 InitTimeoutData(TimeoutData* aData,
-                int32 aTimeoutMs)
+                int32_t aTimeoutMs)
 {
   aData->startTicks = GetTickCount();
   if (!aData->startTicks) {
     // How unlikely is this!
     aData->startTicks++;
   }
   aData->targetTicks = aData->startTicks + aTimeoutMs;
 }
--- a/ipc/ipdl/ipdl/builtin.py
+++ b/ipc/ipdl/ipdl/builtin.py
@@ -32,29 +32,17 @@ Types = (
     'size_t',
     'ssize_t',
 
     # Mozilla types: "less" standard things we know how serialize/deserialize
     'nsresult',
     'nsString',
     'nsCString',
     'mozilla::ipc::Shmem',
-    'mozilla::ipc::FileDescriptor',
-
-    # quasi-stdint types used by "public" Gecko headers
-    'int8',
-    'uint8',
-    'int16',
-    'uint16',
-    'int32',
-    'uint32',
-    'int64',
-    'uint64',
-    'intptr',
-    'uintptr',
+    'mozilla::ipc::FileDescriptor'
 )
 
 
 Includes = (
     'mozilla/Attributes.h',
     'base/basictypes.h',
     'prtime.h',
     'nscore.h',
--- a/ipc/ipdl/ipdl/cxx/ast.py
+++ b/ipc/ipdl/ipdl/cxx/ast.py
@@ -322,20 +322,20 @@ Any type, naked or pointer, can be const
         return Type(self.name,
                     const=self.const,
                     ptr=self.ptr, ptrconst=self.ptrconst,
                     ptrptr=self.ptrptr, ptrconstptr=self.ptrconstptr,
                     ref=self.ref,
                     T=copy.deepcopy(self.T, memo))
 Type.BOOL = Type('bool')
 Type.INT = Type('int')
-Type.INT32 = Type('int32')
+Type.INT32 = Type('int32_t')
 Type.INTPTR = Type('intptr_t')
-Type.UINT32 = Type('uint32')
-Type.UINT32PTR = Type('uint32', ptr=1)
+Type.UINT32 = Type('uint32_t')
+Type.UINT32PTR = Type('uint32_t', ptr=1)
 Type.SIZE = Type('size_t')
 Type.VOID = Type('void')
 Type.VOIDPTR = Type('void', ptr=1)
 
 class TypeArray(Node):
     def __init__(self, basetype, nmemb):
         '''the type |basetype DECLNAME[nmemb]|.  |nmemb| is an Expr'''
         self.basetype = basetype
--- a/ipc/ipdl/ipdl/lower.py
+++ b/ipc/ipdl/ipdl/lower.py
@@ -96,26 +96,26 @@ def _includeGuardEnd(headerfile):
 
 def _messageStartName(ptype):
     return ptype.name() +'MsgStart'
 
 def _protocolId(ptype):
     return ExprVar(_messageStartName(ptype))
 
 def _protocolIdType():
-    return Type('int32')
+    return Type.INT32
 
 def _actorName(pname, side):
     """|pname| is the protocol name. |side| is 'Parent' or 'Child'."""
     tag = side
     if not tag[0].isupper():  tag = side.title()
     return pname + tag
 
 def _actorIdType():
-    return Type('int32')
+    return Type.INT32
 
 def _actorId(actor=None):
     if actor is not None:
         return ExprSelect(actor, '->', 'mId')
     return ExprVar('mId')
 
 def _actorHId(actorhandle):
     return ExprSelect(actorhandle, '.', 'mId')
@@ -1722,21 +1722,21 @@ class _GenerateProtocolCode(ipdl.ast.Vis
         unreachedblock = Block()
         unreachedblock.addstmts([
             _runtimeAbort('corrupted actor state'),
             StmtReturn(ExprLiteral.FALSE) ])
         fromswitch.addcase(DefaultLabel(), unreachedblock)
 
         if usesend:
             transitionfunc.addstmt(
-                StmtDecl(Decl(Type('int32', const=1), sendvar.name),
+                StmtDecl(Decl(Type('int32_t', const=1), sendvar.name),
                          init=ExprVar('mozilla::ipc::Trigger::Send')))
         if userecv:
             transitionfunc.addstmt(
-                StmtDecl(Decl(Type('int32', const=1), recvvar.name),
+                StmtDecl(Decl(Type('int32_t', const=1), recvvar.name),
                          init=ExprVar('mozilla::ipc::Trigger::Recv')))
         if usesend or userecv:
             transitionfunc.addstmt(Whitespace.NL)
 
         transitionfunc.addstmts([
             fromswitch,
             # all --> Error transitions break to here
             StmtExpr(ExprAssn(ExprDeref(nextvar), _errorState())),
--- a/ipc/ipdl/test/cxx/TestDataStructures.cpp
+++ b/ipc/ipdl/test/cxx/TestDataStructures.cpp
@@ -4,17 +4,17 @@
 
 #include "IPDLUnitTests.h"      // fail etc.
 
 typedef InfallibleTArray<nsIntRegion> RegionArray;
 
 namespace mozilla {
 namespace _ipdltest {
 
-static const uint32 nactors = 10;
+static const uint32_t nactors = 10;
 
 #define test_assert(_cond, _msg) \
     if (!(_cond)) fail(_msg)
 
 template<typename T>
 static void
 assert_arrays_equal(InfallibleTArray<T> a, InfallibleTArray<T> b)
 {
@@ -44,17 +44,17 @@ TestDataStructuresParent::TestDataStruct
 TestDataStructuresParent::~TestDataStructuresParent()
 {
     MOZ_COUNT_DTOR(TestDataStructuresParent);
 }
 
 void
 TestDataStructuresParent::Main()
 {
-    for (uint32 i = 0; i < nactors; ++i)
+    for (uint32_t i = 0; i < nactors; ++i)
         if (!SendPTestDataStructuresSubConstructor(i))
             fail("can't alloc actor");
 
     if (!SendStart())
         fail("can't send Start()");
 }
 
 bool
@@ -83,17 +83,17 @@ bool TestDataStructuresParent::RecvTest1
     return true;
 }
 
 bool TestDataStructuresParent::RecvTest2(
         const InfallibleTArray<PTestDataStructuresSubParent*>& i1,
         InfallibleTArray<PTestDataStructuresSubParent*>* o1)
 {
     test_assert(nactors == i1.Length(), "wrong #actors");
-    for (uint32 i = 0; i < i1.Length(); ++i)
+    for (uint32_t i = 0; i < i1.Length(); ++i)
         test_assert(i == Cast(i1[i]).mI, "wrong mI value");
     *o1 = i1;
     return true;
 }
 
 bool TestDataStructuresParent::RecvTest3(
         const IntDouble& i1,
         const IntDouble& i2,
@@ -495,17 +495,17 @@ TestDataStructuresChild::RecvStart()
     Test16();
     Test17();
     if (OtherProcess() != 0) {
         //FIXME/bug 703317 allocation of nsIntRegion uses a global
         //region pool which breaks threads
         Test18();
     }
 
-    for (uint32 i = 0; i < nactors; ++i)
+    for (uint32_t i = 0; i < nactors; ++i)
         if (!PTestDataStructuresSubChild::Send__delete__(mKids[i]))
             fail("can't send dtor");
 
     Close();
 
     return true;
 }
 
--- a/ipc/ipdl/test/cxx/TestDataStructures.h
+++ b/ipc/ipdl/test/cxx/TestDataStructures.h
@@ -15,26 +15,26 @@ namespace _ipdltest {
 //-----------------------------------------------------------------------------
 // Subprotocol actors
 
 class TestDataStructuresSub :
         public PTestDataStructuresSubParent,
         public PTestDataStructuresSubChild
 {
 public:
-    TestDataStructuresSub(uint32 i) : mI(i)
+    TestDataStructuresSub(uint32_t i) : mI(i)
     { }
     virtual ~TestDataStructuresSub()
     { }
     virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE
     {
       if (Deletion != why)
         fail("unexpected destruction!");
     }
-  uint32 mI;
+  uint32_t mI;
 };
 
 //-----------------------------------------------------------------------------
 // Main actors
 
 class TestDataStructuresParent :
     public PTestDataStructuresParent
 {
--- a/js/ipc/ObjectWrapperChild.cpp
+++ b/js/ipc/ObjectWrapperChild.cpp
@@ -22,17 +22,17 @@ using namespace js;
 
 namespace {
 
     class AutoContextPusher {
 
         nsCxPusher mStack;
         JSAutoRequest mRequest;
         JSContext* const mContext;
-        const uint32 mSavedOptions;
+        const uint32_t mSavedOptions;
         JS_DECL_USE_GUARD_OBJECT_NOTIFIER
 
     public:
 
         AutoContextPusher(JSContext* cx
                           JS_GUARD_OBJECT_NOTIFIER_PARAM)
             : mRequest(cx)
             , mContext(cx)