Import of pkgsrc-2016Q3

This commit is contained in:
2016-10-14 07:49:11 +02:00
committed by Lionel Sambuc
parent 9d819b6d54
commit 1242aa1e36
35952 changed files with 949749 additions and 377083 deletions

View File

@@ -0,0 +1,32 @@
$NetBSD: patch-plugins_gpg_gpg_decrypt_attach.php,v 1.1 2016/09/27 12:11:11 manu Exp $
PHP 5 compatibility fix, from Jean-Jacques Puig.
--- plugins/gpg/gpg_decrypt_attach.php.orig
+++ plugins/gpg/gpg_decrypt_attach.php
@@ -181,15 +181,17 @@
return $return;
}
-function scandir($dirstr) {
- // php.net/scandir (PHP5)
- $files = array();
- $fh = opendir($dirstr);
- while (false !== ($filename = readdir($fh))) {
- array_push($files, $filename);
+if (!function_exists('scandir')) {
+ function scandir($dirstr) {
+ // php.net/scandir (PHP5)
+ $files = array();
+ $fh = opendir($dirstr);
+ while (false !== ($filename = readdir($fh))) {
+ array_push($files, $filename);
+ }
+ closedir($fh);
+ return $files;
}
- closedir($fh);
- return $files;
}
/**