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

Unified Diff: remoting/host/win/unprivileged_process_delegate.cc

Issue 810133003: replace NULL->nullptr in src/remoting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 | « remoting/host/win/session_input_injector.cc ('k') | remoting/host/win/window_station_and_desktop.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/win/unprivileged_process_delegate.cc
diff --git a/remoting/host/win/unprivileged_process_delegate.cc b/remoting/host/win/unprivileged_process_delegate.cc
index 2f0bb62fbc1645a1a6a669c2bdefdac8a0c5906a..b79979124f1bf4372efa293c7286dabd6c14f618 100644
--- a/remoting/host/win/unprivileged_process_delegate.cc
+++ b/remoting/host/win/unprivileged_process_delegate.cc
@@ -76,8 +76,9 @@ const char kWorkerThreadSd[] = "O:SYG:SYD:(A;;GA;;;SY)(A;;0x120801;;;BA)";
bool CreateRestrictedToken(ScopedHandle* token_out) {
// Create a token representing LocalService account.
HANDLE temp_handle;
- if (!LogonUser(L"LocalService", L"NT AUTHORITY", NULL, LOGON32_LOGON_SERVICE,
- LOGON32_PROVIDER_DEFAULT, &temp_handle)) {
+ if (!LogonUser(L"LocalService", L"NT AUTHORITY", nullptr,
+ LOGON32_LOGON_SERVICE, LOGON32_PROVIDER_DEFAULT,
+ &temp_handle)) {
return false;
}
ScopedHandle token(temp_handle);
@@ -87,7 +88,7 @@ bool CreateRestrictedToken(ScopedHandle* token_out) {
return false;
// Remove all privileges in the token.
- if (restricted_token.DeleteAllPrivileges(NULL) != ERROR_SUCCESS)
+ if (restricted_token.DeleteAllPrivileges(nullptr) != ERROR_SUCCESS)
return false;
// Set low integrity level if supported by the OS.
@@ -192,8 +193,8 @@ bool CreateWindowStationAndDesktop(ScopedSid logon_sid,
// The default desktop of the interactive window station is called "Default".
// Name the created desktop the same way in case any code relies on that.
// The desktop name should not make any difference though.
- handles.SetDesktop(CreateDesktop(L"Default", NULL, NULL, 0, desired_access,
- &security_attributes));
+ handles.SetDesktop(CreateDesktop(L"Default", nullptr, nullptr, 0,
+ desired_access, &security_attributes));
// Switch back to the original window station.
if (!SetProcessWindowStation(current_window_station)) {
@@ -216,7 +217,7 @@ UnprivilegedProcessDelegate::UnprivilegedProcessDelegate(
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner,
scoped_ptr<base::CommandLine> target_command)
: io_task_runner_(io_task_runner),
- event_handler_(NULL),
+ event_handler_(nullptr),
target_command_(target_command.Pass()) {
}
@@ -311,7 +312,7 @@ void UnprivilegedProcessDelegate::LaunchProcess(
&thread_attributes,
true,
0,
- NULL,
+ nullptr,
&worker_process,
&worker_thread)) {
ReportFatalError();
@@ -343,7 +344,7 @@ void UnprivilegedProcessDelegate::KillProcess() {
DCHECK(CalledOnValidThread());
channel_.reset();
- event_handler_ = NULL;
+ event_handler_ = nullptr;
if (worker_process_.IsValid()) {
TerminateProcess(worker_process_.Get(), CONTROL_C_EXIT);
@@ -385,7 +386,7 @@ void UnprivilegedProcessDelegate::ReportFatalError() {
channel_.reset();
WorkerProcessLauncher* event_handler = event_handler_;
- event_handler_ = NULL;
+ event_handler_ = nullptr;
event_handler->OnFatalError();
}
« no previous file with comments | « remoting/host/win/session_input_injector.cc ('k') | remoting/host/win/window_station_and_desktop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698