aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-07-17 21:34:02 -0700
committerFriendika <info@friendika.com>2011-07-17 21:34:02 -0700
commitf3bd21611204d849c3d28d0c2011f1dc602187da (patch)
tree9a8e7fc99db0b4925c2f6501928e2756eafef27d /boot.php
parent1fa2231c20db99c78f0c8681ebae04b6eecf0954 (diff)
downloadvolse-hubzilla-f3bd21611204d849c3d28d0c2011f1dc602187da.tar.gz
volse-hubzilla-f3bd21611204d849c3d28d0c2011f1dc602187da.tar.bz2
volse-hubzilla-f3bd21611204d849c3d28d0c2011f1dc602187da.zip
bug #104
Diffstat (limited to 'boot.php')
-rw-r--r--boot.php42
1 files changed, 24 insertions, 18 deletions
diff --git a/boot.php b/boot.php
index af510a808..001e3a540 100644
--- a/boot.php
+++ b/boot.php
@@ -1,9 +1,5 @@
<?php
-set_time_limit(0);
-ini_set('pcre.backtrack_limit', 250000);
-
-
define ( 'FRIENDIKA_VERSION', '2.2.1044' );
define ( 'DFRN_PROTOCOL_VERSION', '2.21' );
define ( 'DB_UPDATE_VERSION', 1075 );
@@ -179,20 +175,28 @@ define ( 'GRAVITY_COMMENT', 6);
*
*/
-if (get_magic_quotes_gpc()) {
- $process = array(&$_GET, &$_POST, &$_COOKIE, &$_REQUEST);
- while (list($key, $val) = each($process)) {
- foreach ($val as $k => $v) {
- unset($process[$key][$k]);
- if (is_array($v)) {
- $process[$key][stripslashes($k)] = $v;
- $process[] = &$process[$key][stripslashes($k)];
- } else {
- $process[$key][stripslashes($k)] = stripslashes($v);
- }
- }
- }
- unset($process);
+function startup() {
+ error_reporting(E_ERROR | E_WARNING | E_PARSE);
+ set_time_limit(0);
+ ini_set('pcre.backtrack_limit', 250000);
+
+
+ if (get_magic_quotes_gpc()) {
+ $process = array(&$_GET, &$_POST, &$_COOKIE, &$_REQUEST);
+ while (list($key, $val) = each($process)) {
+ foreach ($val as $k => $v) {
+ unset($process[$key][$k]);
+ if (is_array($v)) {
+ $process[$key][stripslashes($k)] = $v;
+ $process[] = &$process[$key][stripslashes($k)];
+ } else {
+ $process[$key][stripslashes($k)] = stripslashes($v);
+ }
+ }
+ }
+ unset($process);
+ }
+
}
/*
@@ -260,6 +264,8 @@ class App {
$this->query_string = '';
+ startup();
+
$this->scheme = ((isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'])) ? 'https' : 'http' );
if(x($_SERVER,'SERVER_NAME')) {