summaryrefslogtreecommitdiff
path: root/shared
diff options
context:
space:
mode:
Diffstat (limited to 'shared')
-rw-r--r--shared/classes/configuration.php2
-rw-r--r--shared/classes/task.php7
2 files changed, 4 insertions, 5 deletions
diff --git a/shared/classes/configuration.php b/shared/classes/configuration.php
index e315047..a3cdec3 100644
--- a/shared/classes/configuration.php
+++ b/shared/classes/configuration.php
@@ -53,7 +53,7 @@ class sql_configuration extends conf_build_common {
$opt->write();
}
$build->ctime=time();
- $build->status=1;
+ $build->status=-128;
$build->write();
return $build;
}
diff --git a/shared/classes/task.php b/shared/classes/task.php
index d5578b2..571c895 100644
--- a/shared/classes/task.php
+++ b/shared/classes/task.php
@@ -81,7 +81,7 @@ class sql_task extends sql_row_obj {
throw_exception('task has already executed: start is '.$this->start);
}
$this->type='exec';
- log_msg('Executing '.$this->command.'...', false);
+ debug('Executing '.$this->command.'...');
$descriptorspec=array(
0 => array('pipe', 'r'), // STDIN
1 => array('pipe', 'w'), // STDOUT
@@ -98,7 +98,6 @@ class sql_task extends sql_row_obj {
foreach ($pipes as $pipe) {
stream_set_blocking($pipe, 0);
}
- $msg=0;
while (true) {
$null=null; // We have to set these all to variables because stream_select requires pass by reference
$outs=array_slice($pipes, 1);
@@ -108,13 +107,13 @@ class sql_task extends sql_row_obj {
$c=stream_get_contents($pipes[2]);
if ($c) {
// STDERR
- $entry=new sql_buildlog_entry($this->build, $this->order, $msg++, time(), 'stderr', $c);
+ $entry=new sql_buildlog_entry($this->build, $this->order, buildlog_entry_get_order(), time(), 'stderr', $c);
$entry->write();
}
$c=stream_get_contents($pipes[1]);
if ($c) {
// STDOUT
- $entry=new sql_buildlog_entry($this->build, $this->order, $msg++, time(), 'stdout', $c);
+ $entry=new sql_buildlog_entry($this->build, $this->order, buildlog_entry_get_order(), time(), 'stdout', $c);
$entry->write();
}
}