diff options
Diffstat (limited to 'components/nacl/zygote')
-rw-r--r-- | components/nacl/zygote/nacl_fork_delegate_linux.cc | 9 | ||||
-rw-r--r-- | components/nacl/zygote/nacl_fork_delegate_linux.h | 3 |
2 files changed, 5 insertions, 7 deletions
diff --git a/components/nacl/zygote/nacl_fork_delegate_linux.cc b/components/nacl/zygote/nacl_fork_delegate_linux.cc index 049d6f3..558344d 100644 --- a/components/nacl/zygote/nacl_fork_delegate_linux.cc +++ b/components/nacl/zygote/nacl_fork_delegate_linux.cc @@ -329,11 +329,10 @@ pid_t NaClForkDelegate::Fork(const std::string& process_type, return nacl_child; } -bool NaClForkDelegate::AckChild(const int fd, - const std::string& channel_switch) { - int nwritten = HANDLE_EINTR(write(fd, channel_switch.c_str(), - channel_switch.length())); - if (nwritten != static_cast<int>(channel_switch.length())) { +bool NaClForkDelegate::AckChild(const int fd, const std::string& channel_id) { + ssize_t nwritten = + HANDLE_EINTR(write(fd, channel_id.c_str(), channel_id.length())); + if (static_cast<size_t>(nwritten) != channel_id.length()) { return false; } return true; diff --git a/components/nacl/zygote/nacl_fork_delegate_linux.h b/components/nacl/zygote/nacl_fork_delegate_linux.h index 4158a5a..a0860b69 100644 --- a/components/nacl/zygote/nacl_fork_delegate_linux.h +++ b/components/nacl/zygote/nacl_fork_delegate_linux.h @@ -30,8 +30,7 @@ class NaClForkDelegate : public content::ZygoteForkDelegate { int* uma_sample, int* uma_boundary_value) OVERRIDE; virtual pid_t Fork(const std::string& process_type, const std::vector<int>& fds) OVERRIDE; - virtual bool AckChild(int fd, - const std::string& channel_switch) OVERRIDE; + virtual bool AckChild(int fd, const std::string& channel_id) OVERRIDE; virtual bool GetTerminationStatus(pid_t pid, bool known_dead, base::TerminationStatus* status, int* exit_code) OVERRIDE; |