OLD | NEW |
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 "content/browser/renderer_host/render_sandbox_host_linux.h" | 5 #include "content/browser/renderer_host/render_sandbox_host_linux.h" |
6 | 6 |
7 #include <fcntl.h> | 7 #include <fcntl.h> |
8 #include <fontconfig/fontconfig.h> | 8 #include <fontconfig/fontconfig.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 #include <sys/poll.h> | 10 #include <sys/poll.h> |
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
271 WebKit::WebFontFamily family; | 271 WebKit::WebFontFamily family; |
272 WebFontInfo::familyForChars(chars.get(), | 272 WebFontInfo::familyForChars(chars.get(), |
273 num_chars, | 273 num_chars, |
274 preferred_locale.c_str(), | 274 preferred_locale.c_str(), |
275 &family); | 275 &family); |
276 | 276 |
277 Pickle reply; | 277 Pickle reply; |
278 if (family.name.data()) { | 278 if (family.name.data()) { |
279 reply.WriteString(family.name.data()); | 279 reply.WriteString(family.name.data()); |
280 } else { | 280 } else { |
281 reply.WriteString(""); | 281 reply.WriteString(std::string()); |
282 } | 282 } |
283 reply.WriteBool(family.isBold); | 283 reply.WriteBool(family.isBold); |
284 reply.WriteBool(family.isItalic); | 284 reply.WriteBool(family.isItalic); |
285 SendRendererReply(fds, reply, -1); | 285 SendRendererReply(fds, reply, -1); |
286 } | 286 } |
287 | 287 |
288 void HandleGetStyleForStrike(int fd, const Pickle& pickle, | 288 void HandleGetStyleForStrike(int fd, const Pickle& pickle, |
289 PickleIterator iter, | 289 PickleIterator iter, |
290 std::vector<int>& fds) { | 290 std::vector<int>& fds) { |
291 std::string family; | 291 std::string family; |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
734 RenderSandboxHostLinux::~RenderSandboxHostLinux() { | 734 RenderSandboxHostLinux::~RenderSandboxHostLinux() { |
735 if (initialized_) { | 735 if (initialized_) { |
736 if (HANDLE_EINTR(close(renderer_socket_)) < 0) | 736 if (HANDLE_EINTR(close(renderer_socket_)) < 0) |
737 PLOG(ERROR) << "close"; | 737 PLOG(ERROR) << "close"; |
738 if (HANDLE_EINTR(close(childs_lifeline_fd_)) < 0) | 738 if (HANDLE_EINTR(close(childs_lifeline_fd_)) < 0) |
739 PLOG(ERROR) << "close"; | 739 PLOG(ERROR) << "close"; |
740 } | 740 } |
741 } | 741 } |
742 | 742 |
743 } // namespace content | 743 } // namespace content |
OLD | NEW |