From 990b29ed176c85f5f48b913ca13fe79c1c0c2af9 Mon Sep 17 00:00:00 2001 From: "mseaborn@chromium.org" Date: Thu, 29 Jul 2010 12:53:47 +0000 Subject: NaCl: Fix link time error when DISABLE_NACL is set This fixes breakage on the ARM buildbot, introduced by r54113. nacl::Close() is not available when DISABLE_NACL is set. The error was: nacl_process_host.cc: error: undefined reference to 'nacl::Close(int)' BUG=none TEST=none (no trybot for the ARM build) Review URL: http://codereview.chromium.org/3023025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54123 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/nacl_host/nacl_process_host.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'chrome/browser/nacl_host') diff --git a/chrome/browser/nacl_host/nacl_process_host.cc b/chrome/browser/nacl_host/nacl_process_host.cc index 8ae9637..5c9d9da 100644 --- a/chrome/browser/nacl_host/nacl_process_host.cc +++ b/chrome/browser/nacl_host/nacl_process_host.cc @@ -55,12 +55,17 @@ NaClProcessHost::~NaClProcessHost() { if (!reply_msg_) return; + // nacl::Close() is not available at link time if DISABLE_NACL is + // defined, but we still compile a bunch of other code from this + // file anyway. TODO(mseaborn): Make this less messy. +#ifndef DISABLE_NACL for (size_t i = 0; i < sockets_for_renderer_.size(); i++) { nacl::Close(sockets_for_renderer_[i]); } for (size_t i = 0; i < sockets_for_sel_ldr_.size(); i++) { nacl::Close(sockets_for_sel_ldr_[i]); } +#endif // OnProcessLaunched didn't get called because the process couldn't launch. // Don't keep the renderer hanging. -- cgit v1.1