Project

General

Profile

« Previous | Next » 

Revision a1147a30

Added by Doktor Notor over 8 years ago

Fix the pkg_call() and set the timeout to a sane value (Bug #6594)
(cherry picked from commit 9c91c7bd747074b8cdaa90e8810f0c2df081f72d)

View differences:

src/etc/inc/pkg-utils.inc
171 171
	stream_set_blocking($pipes[2], 0);
172 172

  
173 173
	/* XXX: should be a tunnable? */
174
	$timeout = 300; // seconds
174
	$timeout = 60; // seconds
175 175
	$error_log = '';
176 176

  
177 177
	do {
......
179 179
		$read = array($pipes[1], $pipes[2]);
180 180
		$except = array();
181 181

  
182
		$stream = stream_select($read, $write, $except, null, $timeout);
182
		$stream = stream_select($read, $write, $except, $timeout);
183 183
		if ($stream !== FALSE && $stream > 0) {
184 184
			foreach ($read as $pipe) {
185 185
				$content = stream_get_contents($pipe);

Also available in: Unified diff