aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/develop/posting-api.php27
-rw-r--r--phpBB/docs/CHANGELOG.html29
-rw-r--r--phpBB/includes/acp/acp_attachments.php8
-rw-r--r--phpBB/includes/acp/acp_board.php2
-rw-r--r--phpBB/includes/acp/acp_permissions.php2
-rw-r--r--phpBB/includes/auth.php2
-rw-r--r--phpBB/style.php7
7 files changed, 43 insertions, 34 deletions
diff --git a/phpBB/develop/posting-api.php b/phpBB/develop/posting-api.php
index fceabf57f0..31615334c6 100644
--- a/phpBB/develop/posting-api.php
+++ b/phpBB/develop/posting-api.php
@@ -77,7 +77,7 @@ class posting_api
global $db;
// one transaction, we can now garuntee that atomicity of insertions
- $db->transaction('BEGIN');
+ $db->sql_transaction('begin');
$user_id = (int) $data['user_id'];
$forum_id = (int) $data['forum_id'];
@@ -96,8 +96,7 @@ class posting_api
FROM ' . USERS_TABLE . '
WHERE user_id = ' . $user_id;
$result = $db->sql_query($sql);
- $row = $db->sql_fetchrow($result);
- $username = $row['username'];
+ $username = (string) $db->sql_fetchfield('username');
$db->sql_freeresult($result);
}
@@ -125,7 +124,7 @@ class posting_api
'topic_posts' => 1,
'topic_moved_posts' => 0,
'topic_deleted_posts' => 0,
- 'topic_unapproved_posts' => ($approved ? 0 : 1),
+ 'topic_unapproved_posts' => ($approved) ? 0 : 1,
'topic_first_poster_name' => $username,
'topic_poster' => $user_id,
'topic_last_username' => $username,
@@ -179,14 +178,15 @@ class posting_api
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
// we are consistant, victory is ours
- $db->transaction('END');
+ $db->sql_transaction('commit');
}
public function insert_post($data)
{
global $db;
+
// one transaction, we can now garuntee that atomicity of insertions
- $db->transaction('BEGIN');
+ $db->sql_transaction('begin');
$user_id = (int) $data['user_id'];
$topic_id = (int) $data['topic_id'];
@@ -203,8 +203,7 @@ class posting_api
FROM ' . TOPICS_TABLE . '
WHERE topic_id = ' . $topic_id;
$result = $db->sql_query($sql);
- $row = $db->sql_fetchrow($result);
- $forum_id = (int) $row['forum_id'];
+ $forum_id = (int) $db->sql_fetchfield('forum_id');
$db->sql_freeresult($result);
}
@@ -223,8 +222,7 @@ class posting_api
FROM ' . USERS_TABLE . '
WHERE user_id = ' . $user_id;
$result = $db->sql_query($sql);
- $row = $db->sql_fetchrow($result);
- $username = $row['username'];
+ $username = (string) $db->sql_fetchfield('username');
$db->sql_freeresult($result);
}
@@ -298,7 +296,7 @@ class posting_api
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
// we are consistant, victory is ours
- $db->transaction('END');
+ $db->sql_transaction('commit');
}
function move_topic($data)
@@ -306,7 +304,7 @@ class posting_api
global $db;
// lets get this party started
- $db->transaction('BEGIN');
+ $db->sql_transaction('begin');
$topic_id = (int) $data['topic_id'];
$to_forum_id = (int) $data['forum_id'];
@@ -317,6 +315,7 @@ class posting_api
WHERE topic_id = ' . $topic_id;
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
+ $db->sql_freeresult($result);
$topic_status = (int) $row['topic_status'];
$from_forum_id = (int) $row['from_forum_id'];
@@ -326,8 +325,6 @@ class posting_api
$topic_row['topic_deleted_posts'] = (int) $row['topic_deleted_posts'];
$topic_row['topic_unapproved_posts'] = (int) $row['topic_unapproved_posts'];
- $db->sql_freeresult($result);
-
// let us first determine how many items we are removing from the pool
$sql = 'SELECT forum_posts, forum_moved_posts, forum_deleted_posts, forum_unapproved_posts, forum_id, forum_topics, forum_deleted_topics, forum_unapproved_topics
FROM ' . FORUMS_TABLE. '
@@ -448,7 +445,7 @@ class posting_api
// in hundreds of fewer lines of code, we have now moved a topic
// (this totally ignores the shadow topic thingy, I do not care for now)
- $db->transaction('COMMIT');
+ $db->sql_transaction('commit');
}
}
diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 220a7ad5ed..c8caeba819 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -53,6 +53,7 @@
<ol>
<li><a href="#changelog">Changelog</a>
<ol style="list-style-type: lower-roman;">
+ <li><a href="#v301">Changes since 3.0.1</a></li>
<li><a href="#v300">Changes since 3.0.0</a></li>
<li><a href="#v30rc8">Changes since RC-8</a></li>
<li><a href="#v30rc7">Changes since RC-7</a></li>
@@ -81,11 +82,17 @@
<div class="content">
- <a name="v300"></a><h3>1.i. Changes since 3.0.0</h3>
+ <a name="v301"></a><h3>1.i. Changes since 3.0.1</h3>
<ul>
- <li>[Change] Migrate phpBB to PHP versions >= 5.1</li>
+ <li>[Fix] Ability to set permissions on non-mysql dbms (Bug #24955)</li>
+ <li>[Fix] Fixed blank style on setups having no username defined within config.php (Bug #25065)</li>
+ </ul>
+
+ <a name="v300"></a><h3>1.ii. Changes since 3.0.0</h3>
+ <ul>
+ <li>[Change] Migrate phpBB to PHP versions >= 5.1</li>
<li>[Change] Validate birthdays (Bug #15004)</li>
<li>[Fix] Allow correct avatar caching for CGI installations. (thanks wildbill)</li>
<li>[Fix] Fix disabling of word censor, now possible again</li>
@@ -148,9 +155,13 @@
<li>[Sec] Check for non-empty config.php within style.php (Report #s24575) - reported by bantu</li>
</ul>
+<<<<<<< .working
</ul>
<a name="v30rc8"></a><h3>1.i. Changes since 3.0.RC8</h3>
+=======
+ <a name="v30rc8"></a><h3>1.iii. Changes since 3.0.RC8</h3>
+>>>>>>> .merge-right.r8502
<ul>
<li>[Fix] Cleaned usernames contain only single spaces, so &quot;a_name&quot; and &quot;a__name&quot; are treated as the same name (Bug #15634)</li>
@@ -159,7 +170,7 @@
<li>[Fix] Call garbage_collection() within database updater to correctly close connections (affects Oracle for example)</li>
</ul>
- <a name="v30rc7"></a><h3>1.ii. Changes since 3.0.RC7</h3>
+ <a name="v30rc7"></a><h3>1.iv. Changes since 3.0.RC7</h3>
<ul>
<li>[Fix] Fixed MSSQL related bug in the update system</li>
@@ -194,7 +205,7 @@
<li>[Fix] No duplication of active topics (Bug #15474)</li>
</ul>
- <a name="v30rc6"></a><h3>1.iii. Changes since 3.0.RC6</h3>
+ <a name="v30rc6"></a><h3>1.v. Changes since 3.0.RC6</h3>
<ul>
<li>[Fix] Submitting language changes using acp_language (Bug #14736)</li>
@@ -204,7 +215,7 @@
<li>[Fix] Able to request new password (Bug #14743)</li>
</ul>
- <a name="v30rc5"></a><h3>1.iv. Changes since 3.0.RC5</h3>
+ <a name="v30rc5"></a><h3>1.vi. Changes since 3.0.RC5</h3>
<ul>
<li>[Feature] Removing constant PHPBB_EMBEDDED in favor of using an exit_handler(); the constant was meant to achive this more or less.</li>
@@ -267,7 +278,7 @@
<li>[Sec] New password hashing mechanism for storing passwords (#i42)</li>
</ul>
- <a name="v30rc4"></a><h3>1.v. Changes since 3.0.RC4</h3>
+ <a name="v30rc4"></a><h3>1.vii. Changes since 3.0.RC4</h3>
<ul>
<li>[Fix] MySQL, PostgreSQL and SQLite related database fixes (Bug #13862)</li>
@@ -318,7 +329,7 @@
<li>[Fix] odbc_autocommit causing existing result sets to be dropped (Bug #14182)</li>
</ul>
- <a name="v30rc3"></a><h3>1.vi. Changes since 3.0.RC3</h3>
+ <a name="v30rc3"></a><h3>1.viii. Changes since 3.0.RC3</h3>
<ul>
<li>[Fix] Fixing some subsilver2 and prosilver style issues</li>
@@ -427,7 +438,7 @@
</ul>
- <a name="v30rc2"></a><h3>1.vii. Changes since 3.0.RC2</h3>
+ <a name="v30rc2"></a><h3>1.ix. Changes since 3.0.RC2</h3>
<ul>
<li>[Fix] Re-allow searching within the memberlist</li>
@@ -473,7 +484,7 @@
</ul>
- <a name="v30rc1"></a><h3>1.viii. Changes since 3.0.RC1</h3>
+ <a name="v30rc1"></a><h3>1.x. Changes since 3.0.RC1</h3>
<ul>
<li>[Fix] (X)HTML issues within the templates (Bug #11255, #11255)</li>
diff --git a/phpBB/includes/acp/acp_attachments.php b/phpBB/includes/acp/acp_attachments.php
index 0d0f058392..9ddd8ff582 100644
--- a/phpBB/includes/acp/acp_attachments.php
+++ b/phpBB/includes/acp/acp_attachments.php
@@ -273,13 +273,19 @@ class acp_attachments
{
$l_explain = (isset($user->lang[$vars['lang'] . '_EXPLAIN'])) ? $user->lang[$vars['lang'] . '_EXPLAIN'] : '';
}
+
+ $content = build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars);
+ if (empty($content))
+ {
+ continue;
+ }
$template->assign_block_vars('options', array(
'KEY' => $config_key,
'TITLE' => $user->lang[$vars['lang']],
'S_EXPLAIN' => $vars['explain'],
'TITLE_EXPLAIN' => $l_explain,
- 'CONTENT' => build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars),
+ 'CONTENT' => $content,
)
);
diff --git a/phpBB/includes/acp/acp_board.php b/phpBB/includes/acp/acp_board.php
index c1e94000db..0e9be94550 100644
--- a/phpBB/includes/acp/acp_board.php
+++ b/phpBB/includes/acp/acp_board.php
@@ -565,7 +565,7 @@ class acp_board
'TITLE' => (isset($user->lang[$vars['lang']])) ? $user->lang[$vars['lang']] : $vars['lang'],
'S_EXPLAIN' => $vars['explain'],
'TITLE_EXPLAIN' => $l_explain,
- 'CONTENT' => build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars),
+ 'CONTENT' => $content,
)
);
diff --git a/phpBB/includes/acp/acp_permissions.php b/phpBB/includes/acp/acp_permissions.php
index a9e64b74ae..9240db271c 100644
--- a/phpBB/includes/acp/acp_permissions.php
+++ b/phpBB/includes/acp/acp_permissions.php
@@ -1156,7 +1156,7 @@ class acp_permissions
}
// Not ideal, due to the filesort, non-use of indexes, etc.
- $sql = 'SELECT DISTINCT u.user_id, u.username
+ $sql = 'SELECT DISTINCT u.user_id, u.username, u.username_clean, u.user_regdate
FROM ' . USERS_TABLE . ' u, ' . ACL_USERS_TABLE . " a
WHERE u.user_id = a.user_id
$sql_forum_id
diff --git a/phpBB/includes/auth.php b/phpBB/includes/auth.php
index 16accea94e..3512d14d56 100644
--- a/phpBB/includes/auth.php
+++ b/phpBB/includes/auth.php
@@ -801,7 +801,7 @@ class auth
{
$this->_set_group_hold_ary($hold_ary[$row['forum_id']], $row['auth_option_id'], $row['auth_setting']);
}
- else
+ else if (!empty($this->role_cache[$row['auth_role_id']]))
{
foreach (unserialize($this->role_cache[$row['auth_role_id']]) as $option_id => $setting)
{
diff --git a/phpBB/style.php b/phpBB/style.php
index 6d5705a074..575715b605 100644
--- a/phpBB/style.php
+++ b/phpBB/style.php
@@ -21,7 +21,7 @@ date_default_timezone_set('UTC');
require($phpbb_root_path . 'config.' . $phpEx);
-if (!defined('PHPBB_INSTALLED') || empty($dbms) || !isset($dbhost) || !isset($dbpasswd) || empty($dbuser))
+if (!defined('PHPBB_INSTALLED') || empty($dbms) || empty($acm_type))
{
exit;
}
@@ -58,11 +58,6 @@ if (strspn($sid, 'abcdefABCDEF0123456789') !== strlen($sid))
// server a little
if ($id)
{
- if (empty($acm_type) || empty($dbms))
- {
- die('Hacking attempt');
- }
-
// Include files
require($phpbb_root_path . 'includes/acm/acm_' . $acm_type . '.' . $phpEx);
require($phpbb_root_path . 'includes/cache.' . $phpEx);