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

Side by Side Diff: net/base/network_interfaces_unittest.cc

Issue 1158923005: Use the exact-width integer types defined in <stdint.h> rather than (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Tweak comments. Exclude mime_sniffer*. Rebase. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/base/network_interfaces.h" 5 #include "net/base/network_interfaces.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include <ostream> 9 #include <ostream>
10 10
(...skipping 631 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 EXPECT_EQ(std::string(), internal::GetWifiSSIDFromInterfaceListInternal( 642 EXPECT_EQ(std::string(), internal::GetWifiSSIDFromInterfaceListInternal(
643 list, TestGetInterfaceSSID)); 643 list, TestGetInterfaceSSID));
644 } 644 }
645 #endif // OS_LINUX 645 #endif // OS_LINUX
646 646
647 #if defined(OS_WIN) 647 #if defined(OS_WIN)
648 bool read_int_or_bool(DWORD data_size, 648 bool read_int_or_bool(DWORD data_size,
649 PVOID data) { 649 PVOID data) {
650 switch (data_size) { 650 switch (data_size) {
651 case 1: 651 case 1:
652 return !!*reinterpret_cast<uint8*>(data); 652 return !!*reinterpret_cast<uint8_t*>(data);
653 case 4: 653 case 4:
654 return !!*reinterpret_cast<uint32*>(data); 654 return !!*reinterpret_cast<uint32_t*>(data);
655 default: 655 default:
656 LOG(FATAL) << "That is not a type I know!"; 656 LOG(FATAL) << "That is not a type I know!";
657 return false; 657 return false;
658 } 658 }
659 } 659 }
660 660
661 int GetWifiOptions() { 661 int GetWifiOptions() {
662 const internal::WlanApi& wlanapi = internal::WlanApi::GetInstance(); 662 const internal::WlanApi& wlanapi = internal::WlanApi::GetInstance();
663 if (!wlanapi.initialized) 663 if (!wlanapi.initialized)
664 return -1; 664 return -1;
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
745 TryChangeWifiOptions(0); 745 TryChangeWifiOptions(0);
746 TryChangeWifiOptions(WIFI_OPTIONS_DISABLE_SCAN); 746 TryChangeWifiOptions(WIFI_OPTIONS_DISABLE_SCAN);
747 TryChangeWifiOptions(WIFI_OPTIONS_MEDIA_STREAMING_MODE); 747 TryChangeWifiOptions(WIFI_OPTIONS_MEDIA_STREAMING_MODE);
748 TryChangeWifiOptions(WIFI_OPTIONS_DISABLE_SCAN | 748 TryChangeWifiOptions(WIFI_OPTIONS_DISABLE_SCAN |
749 WIFI_OPTIONS_MEDIA_STREAMING_MODE); 749 WIFI_OPTIONS_MEDIA_STREAMING_MODE);
750 } 750 }
751 751
752 } // namespace 752 } // namespace
753 753
754 } // namespace net 754 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698