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

Side by Side Diff: chrome/installer/util/delete_reg_value_work_item.h

Issue 151101: Fixit: Remove bunch of coverity warnings from chrome/installer/*. (Closed)
Patch Set: Created 11 years, 5 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #ifndef CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_ 5 #ifndef CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_
6 #define CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_ 6 #define CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_
7 7
8 #include <string> 8 #include <string>
9 #include <windows.h> 9 #include <windows.h>
10 #include "chrome/installer/util/work_item.h" 10 #include "chrome/installer/util/work_item.h"
11 11
(...skipping 16 matching lines...) Expand all
28 // One possible outcome after Do(). Value is deleted. 28 // One possible outcome after Do(). Value is deleted.
29 VALUE_DELETED, 29 VALUE_DELETED,
30 // One possible outcome after Do(). Value is not found. 30 // One possible outcome after Do(). Value is not found.
31 VALUE_NOT_FOUND, 31 VALUE_NOT_FOUND,
32 // The status after Do() and Rollback() is called. 32 // The status after Do() and Rollback() is called.
33 VALUE_ROLLED_BACK, 33 VALUE_ROLLED_BACK,
34 // Another possible outcome after Do() (when there is an error). 34 // Another possible outcome after Do() (when there is an error).
35 VALUE_UNCHANGED 35 VALUE_UNCHANGED
36 }; 36 };
37 37
38 DeleteRegValueWorkItem(HKEY predefined_root, std::wstring key_path, 38 DeleteRegValueWorkItem(HKEY predefined_root, const std::wstring& key_path,
39 std::wstring value_name, bool is_str_type); 39 const std::wstring& value_name, bool is_str_type);
40 40
41 // Root key of the target key under which the value is set. The root key can 41 // Root key of the target key under which the value is set. The root key can
42 // only be one of the predefined keys on Windows. 42 // only be one of the predefined keys on Windows.
43 HKEY predefined_root_; 43 HKEY predefined_root_;
44 44
45 // Path of the target key under which the value is set. 45 // Path of the target key under which the value is set.
46 std::wstring key_path_; 46 std::wstring key_path_;
47 47
48 // Name of the value to be set. 48 // Name of the value to be set.
49 std::wstring value_name_; 49 std::wstring value_name_;
50 50
51 // boolean that tells whether data value is of type REG_SZ or REG_DWORD. 51 // boolean that tells whether data value is of type REG_SZ or REG_DWORD.
52 // Ideally we do not need this information from user of this class and can 52 // Ideally we do not need this information from user of this class and can
53 // check the registry for the type. But to simpify implementation we are 53 // check the registry for the type. But to simpify implementation we are
54 // going to put the burden on the caller for now to provide us the type. 54 // going to put the burden on the caller for now to provide us the type.
55 bool is_str_type_; 55 bool is_str_type_;
56 56
57 DeletionStatus status_; 57 DeletionStatus status_;
58 58
59 // Data of the previous value. 59 // Data of the previous value.
60 std::wstring old_str_; // if data is of type REG_SZ 60 std::wstring old_str_; // if data is of type REG_SZ
61 DWORD old_dw_; // if data is of type REG_DWORD 61 DWORD old_dw_; // if data is of type REG_DWORD
62 }; 62 };
63 63
64 #endif // CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_ 64 #endif // CHROME_INSTALLER_UTIL_DELETE_REG_VALUE_WORK_ITEM_H_
OLDNEW
« no previous file with comments | « chrome/installer/util/create_reg_key_work_item.cc ('k') | chrome/installer/util/delete_reg_value_work_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698