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

Unified Diff: sandbox/src/file_policy_test.cc

Issue 2222002: Unsigned warning fix - take 2 (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/tools/dump_cache/upgrade.cc ('k') | sandbox/src/interception_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/src/file_policy_test.cc
===================================================================
--- sandbox/src/file_policy_test.cc (revision 48256)
+++ sandbox/src/file_policy_test.cc (working copy)
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -262,8 +262,8 @@
// Create a temp file because we need write access to it.
wchar_t temp_directory[MAX_PATH];
wchar_t temp_file_name[MAX_PATH];
- ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0);
+ ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0u);
EXPECT_TRUE(runner.AddFsRule(TargetPolicy::FILES_ALLOW_READONLY,
temp_file_name));
@@ -292,8 +292,8 @@
// Create a temp file because we need write access to it.
wchar_t temp_directory[MAX_PATH];
wchar_t temp_file_name[MAX_PATH];
- ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0);
+ ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0u);
wcscat_s(temp_directory, MAX_PATH, L"*");
EXPECT_TRUE(runner.AddFsRule(TargetPolicy::FILES_ALLOW_ANY, temp_directory));
@@ -384,15 +384,15 @@
wchar_t temp_file_name6[MAX_PATH];
wchar_t temp_file_name7[MAX_PATH];
wchar_t temp_file_name8[MAX_PATH];
- ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name1), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name2), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name3), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name4), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name5), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name6), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name7), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name8), 0);
+ ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name1), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name2), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name3), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name4), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name5), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name6), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name7), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name8), 0u);
// Add rules to make file1->file2 succeed.
@@ -500,8 +500,8 @@
// Create a temp file because we need write access to it.
wchar_t temp_directory[MAX_PATH];
wchar_t temp_file_name[MAX_PATH];
- ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0);
- ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0);
+ ASSERT_NE(::GetTempPath(MAX_PATH, temp_directory), 0u);
+ ASSERT_NE(::GetTempFileName(temp_directory, L"test", 0, temp_file_name), 0u);
// Delete the file and create a directory instead.
ASSERT_TRUE(::DeleteFile(temp_file_name));
« no previous file with comments | « net/tools/dump_cache/upgrade.cc ('k') | sandbox/src/interception_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698