com web/rmtools: fix call method on non object: script/pecl.php
| From: | Anatol Belski | Date: | Sat, 19 Nov 2016 15:55:41 +0000 |
| Subject: | com web/rmtools: fix call method on non object: script/pecl.php | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-25895@lists.php.net to get a copy of this message | ||
Commit: ee40a45f9c453d9d464c8fb5a2c19d098310a373
Author: Anatol Belski <ab@php.net> Sat, 19 Nov 2016 16:55:41 +0100
Parents: 31351e1f243eb6d7e2fb563d746039d81fbbefe2
Branches: master
Link: http://git.php.net/?p=web/rmtools.git;a=commitdiff;h=ee40a45f9c453d9d464c8fb5a2c19d098310a373
Log:
fix call method on non object
Changed paths:
M script/pecl.php
Diff:
diff --git a/script/pecl.php b/script/pecl.php
index 4538e8c..d6b7f9d 100644
--- a/script/pecl.php
+++ b/script/pecl.php
@@ -128,7 +128,7 @@ foreach ($builds as $build_name) {
$build->setSourceDir($build_src_path);
} catch (Exception $e) {
echo 'Error: ' . $e->getMessage() . PHP_EOL;
- $build->clean();
+ $build && $build->clean();
$was_errors = true;
unset($build);