Do not redirect stderr of Apache process

Apache gets stuck when the pipe connected to stderr gets filled up and
not read. This patch makes stderr of apache directly goes to build log.

BUG=30536, 431172

Review URL: https://codereview.chromium.org/712253002

git-svn-id: svn://svn.chromium.org/blink/trunk@185164 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 97944c93
...@@ -126,12 +126,10 @@ class ApacheHTTP(server_base.ServerBase): ...@@ -126,12 +126,10 @@ class ApacheHTTP(server_base.ServerBase):
def _spawn_process(self): def _spawn_process(self):
_log.debug('Starting %s server, cmd="%s"' % (self._name, str(self._start_cmd))) _log.debug('Starting %s server, cmd="%s"' % (self._name, str(self._start_cmd)))
self._process = self._executive.popen(self._start_cmd, stderr=self._executive.PIPE) self._process = self._executive.popen(self._start_cmd)
if self._process.returncode is not None: retval = self._process.returncode
retval = self._process.returncode if retval:
err = self._process.stderr.read() raise server_base.ServerError('Failed to start %s: %s' % (self._name, retval))
if retval or len(err):
raise server_base.ServerError('Failed to start %s: %s' % (self._name, err))
# For some reason apache isn't guaranteed to have created the pid file before # For some reason apache isn't guaranteed to have created the pid file before
# the process exits, so we wait a little while longer. # the process exits, so we wait a little while longer.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment