diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 80573d5483..b16491a6cb 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -260,6 +260,7 @@ p a {
[Fix] Allow for conversions to SQLite (Bug #12279) - patch provided by ToonArmy
[Fix] Apply colors to guests (Bug #12219)
[Fix] Set the Admin group as founder_manage during conversion (Bug #12287)
+ [Fix] Fixed a special quote BBCode case (Bug #12189)
diff --git a/phpBB/includes/message_parser.php b/phpBB/includes/message_parser.php
index 370a409d2f..56c31b7818 100644
--- a/phpBB/includes/message_parser.php
+++ b/phpBB/includes/message_parser.php
@@ -690,7 +690,7 @@ class bbcode_firstpass extends bbcode
if ($tok == ']')
{
- if ($buffer == '/quote' && sizeof($close_tags))
+ if ($buffer == '/quote' && sizeof($close_tags) && substr($out, -1, 1) == '[')
{
// we have found a closing tag
$out .= array_pop($close_tags) . ']';