aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2008-09-30 09:49:20 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2008-09-30 09:49:20 +0000
commit77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394 (patch)
treebc1007e194cf34eca13683d7e21818b04ec213d0 /phpBB
parenteef41d039edecdb80b52a4122dacd874d0e1b807 (diff)
downloadforums-77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394.tar
forums-77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394.tar.gz
forums-77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394.tar.bz2
forums-77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394.tar.xz
forums-77cf8e50d9e1b37cdd5ba5bb409ce6ac09fba394.zip
further adjustments to exit; statements
force E_USER_ERROR to exit *always* - it is always a fatal error which should stop every execution happening git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8957 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/includes/functions.php3
-rw-r--r--phpBB/mcp.php5
-rw-r--r--phpBB/posting.php6
-rw-r--r--phpBB/viewforum.php2
4 files changed, 10 insertions, 6 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index fc3257dfd8..0c5daa9231 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -3228,6 +3228,9 @@ function msg_handler($errno, $msg_text, $errfile, $errline)
echo '</html>';
exit_handler();
+
+ // On a fatal error (and E_USER_ERROR *is* fatal) we never want other scripts to continue and force an exit here.
+ exit;
break;
case E_USER_WARNING:
diff --git a/phpBB/mcp.php b/phpBB/mcp.php
index cb6c14ca0c..5e8102d774 100644
--- a/phpBB/mcp.php
+++ b/phpBB/mcp.php
@@ -166,7 +166,7 @@ if ($quickmod)
case 'delete_post':
case 'delete_topic':
$module->load('mcp', 'main', 'quickmod');
- exit;
+ return;
break;
case 'topic_logs':
@@ -183,7 +183,8 @@ if ($quickmod)
break;
default:
- trigger_error("$action not allowed as quickmod");
+ trigger_error("$action not allowed as quickmod", E_USER_ERROR);
+ break;
}
}
else
diff --git a/phpBB/posting.php b/phpBB/posting.php
index 057d8b3b41..4cfd1d7d72 100644
--- a/phpBB/posting.php
+++ b/phpBB/posting.php
@@ -114,7 +114,7 @@ switch ($mode)
else
{
upload_popup();
- exit;
+ return;
}
break;
@@ -145,7 +145,7 @@ if (!$post_data)
if ($mode == 'popup')
{
upload_popup($post_data['forum_style']);
- exit;
+ return;
}
$user->setup(array('posting', 'mcp', 'viewtopic'), $post_data['forum_style']);
@@ -276,7 +276,7 @@ if ($mode == 'edit' && !$auth->acl_get('m_edit', $forum_id))
if ($mode == 'delete')
{
handle_post_delete($forum_id, $topic_id, $post_id, $post_data);
- exit;
+ return;
}
// Handle bump mode...
diff --git a/phpBB/viewforum.php b/phpBB/viewforum.php
index b95a009baa..7e53a13ff7 100644
--- a/phpBB/viewforum.php
+++ b/phpBB/viewforum.php
@@ -113,7 +113,7 @@ if ($forum_data['forum_type'] == FORUM_LINK && $forum_data['forum_link'])
// We redirect to the url. The third parameter indicates that external redirects are allowed.
redirect($forum_data['forum_link'], false, true);
- exit;
+ return;
}
// Build navigation links