chore: use emplace when possible (#37877)

This commit is contained in:
David Sanders 2023-04-10 23:21:03 -07:00 committed by GitHub
parent 3c0c4d5c27
commit 82442239bc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 9 deletions

View file

@ -82,8 +82,8 @@ int LaunchProgram(const StringVector& relauncher_args,
base::LaunchOptions options;
options.new_process_group = true; // detach
options.fds_to_remap.push_back(std::make_pair(devnull.get(), STDERR_FILENO));
options.fds_to_remap.push_back(std::make_pair(devnull.get(), STDOUT_FILENO));
options.fds_to_remap.emplace_back(devnull.get(), STDERR_FILENO);
options.fds_to_remap.emplace_back(devnull.get(), STDOUT_FILENO);
base::Process process = base::LaunchProcess(argv, options);
return process.IsValid() ? 0 : 1;