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

Side by Side Diff: win8/delegate_execute/delegate_execute_operation.cc

Issue 1284833004: Remove remaining legacy SplitString calls. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « tools/ipc_fuzzer/message_tools/message_util.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "win8/delegate_execute/delegate_execute_operation.h" 5 #include "win8/delegate_execute/delegate_execute_operation.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "base/strings/string_split.h" 9 #include "base/strings/string_split.h"
10 #include "base/win/windows_version.h" 10 #include "base/win/windows_version.h"
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 else if (cmd_line->HasSwitch(switches::kForceImmersive)) 45 else if (cmd_line->HasSwitch(switches::kForceImmersive))
46 the_switch = switches::kForceImmersive; 46 the_switch = switches::kForceImmersive;
47 47
48 relaunch_flags_ = ParametersFromSwitch(the_switch); 48 relaunch_flags_ = ParametersFromSwitch(the_switch);
49 49
50 operation_type_ = RELAUNCH_CHROME; 50 operation_type_ = RELAUNCH_CHROME;
51 return true; 51 return true;
52 } 52 }
53 53
54 base::Process DelegateExecuteOperation::GetParent() const { 54 base::Process DelegateExecuteOperation::GetParent() const {
55 std::vector<base::string16> parts; 55 std::vector<base::StringPiece16> parts = base::SplitStringPiece(
56 base::SplitString(mutex_, L'.', &parts); 56 mutex_, L".", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL);
57 if (parts.size() != 3) 57 if (parts.size() != 3)
58 return base::Process(); 58 return base::Process();
59 DWORD pid; 59 DWORD pid;
60 if (!base::StringToUint(parts[2], reinterpret_cast<uint32*>(&pid))) 60 if (!base::StringToUint(parts[2], reinterpret_cast<uint32*>(&pid)))
61 return base::Process(); 61 return base::Process();
62 return base::Process::Open(pid); 62 return base::Process::Open(pid);
63 } 63 }
64 64
65 } // namespace delegate_execute 65 } // namespace delegate_execute
OLDNEW
« no previous file with comments | « tools/ipc_fuzzer/message_tools/message_util.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698