Do not use realpath() on includes.
If the file does not exist, realpath() returns false and "include false;" produces "Failed opening '' for inclusion" which is a useless error message. 'include' works just fine with symlinks, "./" and "../".
This commit is contained in:
parent
12f4494de0
commit
9753e44ac2
|
@ -25,7 +25,7 @@
|
|||
|
||||
namespace OCA\Encryption;
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php');
|
||||
require_once dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php';
|
||||
|
||||
/**
|
||||
* Class for common cryptography functionality
|
||||
|
|
|
@ -7,16 +7,16 @@
|
|||
* See the COPYING-README file.
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/helper.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php';
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../lib/helper.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -6,15 +6,15 @@
|
|||
* See the COPYING-README file.
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/helper.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../lib/helper.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -20,16 +20,16 @@
|
|||
*
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/helper.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../3rdparty/Crypt_Blowfish/Blowfish.php';
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../lib/helper.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -20,14 +20,14 @@
|
|||
*
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -20,15 +20,15 @@
|
|||
*
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../../files_trashbin/appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/../../files_trashbin/appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
* See the COPYING-README file.
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
|
@ -20,14 +20,14 @@
|
|||
*
|
||||
*/
|
||||
|
||||
require_once realpath(dirname(__FILE__) . '/../../../lib/base.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/crypt.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/keymanager.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/proxy.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/stream.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../lib/util.php');
|
||||
require_once realpath(dirname(__FILE__) . '/../appinfo/app.php');
|
||||
require_once realpath(dirname(__FILE__) . '/util.php');
|
||||
require_once dirname(__FILE__) . '/../../../lib/base.php';
|
||||
require_once dirname(__FILE__) . '/../lib/crypt.php';
|
||||
require_once dirname(__FILE__) . '/../lib/keymanager.php';
|
||||
require_once dirname(__FILE__) . '/../lib/proxy.php';
|
||||
require_once dirname(__FILE__) . '/../lib/stream.php';
|
||||
require_once dirname(__FILE__) . '/../lib/util.php';
|
||||
require_once dirname(__FILE__) . '/../appinfo/app.php';
|
||||
require_once dirname(__FILE__) . '/util.php';
|
||||
|
||||
use OCA\Encryption;
|
||||
|
||||
|
|
Loading…
Reference in New Issue