aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/search/fulltext_postgres.php
diff options
context:
space:
mode:
authorTristan Darricau <tristan.darricau@sensiolabs.com>2015-12-08 19:45:43 +0100
committerTristan Darricau <tristan.darricau@sensiolabs.com>2015-12-08 19:45:43 +0100
commit9130f20cb650a8ea244cf258fd579d2b208be311 (patch)
treecce446f9781dbb6475cb7e94e1343be8f6c950dc /phpBB/phpbb/search/fulltext_postgres.php
parent398590b7ab6c9f620a4b2d73fd64899be5c9afc3 (diff)
parent6188a8777950ffeaa80593d815600c84911ac932 (diff)
downloadforums-9130f20cb650a8ea244cf258fd579d2b208be311.tar
forums-9130f20cb650a8ea244cf258fd579d2b208be311.tar.gz
forums-9130f20cb650a8ea244cf258fd579d2b208be311.tar.bz2
forums-9130f20cb650a8ea244cf258fd579d2b208be311.tar.xz
forums-9130f20cb650a8ea244cf258fd579d2b208be311.zip
Merge pull request #4072 from marc1706/ticket/14344
[ticket/14344] Improve output of HTML errors trigged during install * marc1706/ticket/14344: [ticket/14344] Improve output of HTML errors trigged during install
Diffstat (limited to 'phpBB/phpbb/search/fulltext_postgres.php')
0 files changed, 0 insertions, 0 deletions
va.com>2002-07-26 17:03:10 +0000 committerPascal Rigaux <pixel@mandriva.com>2002-07-26 17:03:10 +0000 commit2e83b63adaf8acfa9a25c2e169525e1c5534f437 (patch) treed0ca89474bcb7067c91be52a7d6c43f8d0a3cc0e /perl-install/run_program.pm parent6990f9fecf2642e7a876717091968d4f7872562c (diff)downloaddrakx-2e83b63adaf8acfa9a25c2e169525e1c5534f437.tar
drakx-2e83b63adaf8acfa9a25c2e169525e1c5534f437.tar.gz
drakx-2e83b63adaf8acfa9a25c2e169525e1c5534f437.tar.bz2
drakx-2e83b63adaf8acfa9a25c2e169525e1c5534f437.tar.xz
drakx-2e83b63adaf8acfa9a25c2e169525e1c5534f437.zip
- also give the ability to redirect to an array ref
- add rooted_get_stdout which is alike ``
Diffstat (limited to 'perl-install/run_program.pm')
-rw-r--r--perl-install/run_program.pm19
1 files changed, 17 insertions, 2 deletions
diff --git a/perl-install/run_program.pm b/perl-install/run_program.pm
index a0d5c98dc..a50f31f0a 100644
--- a/perl-install/run_program.pm
+++ b/perl-install/run_program.pm
@@ -16,6 +16,13 @@ sub rooted_or_die {
my ($root, $name, @args) = @_;
rooted($root, $name, @args) or die "$name failed\n";
}
+sub rooted_get_stdout {
+ my ($root, $name, @args) = @_;
+ my @r;
+ rooted($root, $name, '>', \@r, @args) or return;
+ @r;
+}
+
sub run { rooted('', @_) }
sub rooted {
@@ -41,11 +48,19 @@ sub rooted {
waitpid $pid, 0;
$? == 0 or return;
if ($stdout_raw && ref($stdout_raw)) {
- $$stdout_raw = cat_($stdout);
+ if (ref($stdout_raw) eq 'ARRAY') {
+ @$stdout_raw = cat_($stdout);
+ } else {
+ $$stdout_raw = cat_($stdout);
+ }
unlink $stdout;
}
if ($stderr_raw && ref($stderr_raw)) {
- $$stderr_raw = cat_($stderr);
+ if (ref($stderr_raw) eq 'ARRAY') {
+ @$stderr_raw = cat_($stderr);
+ } else {
+ $$stderr_raw = cat_($stderr);
+ }
unlink $stderr;
}
1;