diff options
author | Phil Davis <phil.davis@inf.org> | 2016-06-27 14:30:14 +0930 |
---|---|---|
committer | Chris Buechler <cmb@pfsense.org> | 2016-06-27 14:16:13 -0500 |
commit | aceaf18c1ad93c808b77e0bbf324949d5d2eede0 (patch) | |
tree | cc34e086600b4a481586e35eb6142a1b46799679 /src/usr/local/www/xmlrpc.php | |
parent | 9d265a8db874249ac16d4d02ce68463416f1aee2 (diff) | |
download | pfsense-aceaf18c1ad93c808b77e0bbf324949d5d2eede0.zip pfsense-aceaf18c1ad93c808b77e0bbf324949d5d2eede0.tar.gz |
Always use require_once
The usage of require() and require_once() throughout the system is
inconsistent, and "bugs" come up now and then when the order of
"requires" is a bit different and some require() happens after the
include file is already included/required.
It seems to me that there is no harm at all in always using
require_once().
Diffstat (limited to 'src/usr/local/www/xmlrpc.php')
-rwxr-xr-x | src/usr/local/www/xmlrpc.php | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/usr/local/www/xmlrpc.php b/src/usr/local/www/xmlrpc.php index c516c54..66d4997 100755 --- a/src/usr/local/www/xmlrpc.php +++ b/src/usr/local/www/xmlrpc.php @@ -61,14 +61,14 @@ ##|*MATCH=xmlrpc.php* ##|-PRIV -require("config.inc"); -require("functions.inc"); +require_once("config.inc"); +require_once("functions.inc"); require_once("filter.inc"); -require("ipsec.inc"); -require("vpn.inc"); -require("shaper.inc"); -require("xmlrpc_server.inc"); -require("xmlrpc.inc"); +require_once("ipsec.inc"); +require_once("vpn.inc"); +require_once("shaper.inc"); +require_once("xmlrpc_server.inc"); +require_once("xmlrpc.inc"); function xmlrpc_loop_detect() { global $config; @@ -532,7 +532,7 @@ function get_notices_xmlrpc($raw_params) { return $xmlrpc_g['return']['authfail']; } if (!function_exists("get_notices")) { - require("notices.inc"); + require_once("notices.inc"); } if (!$params) { $toreturn = get_notices(); |