[wp-trac] [WordPress Trac] #37689: Issues with utf8mb4 collation and the 4.6 update
WordPress Trac
noreply at wordpress.org
Tue Aug 30 07:41:13 UTC 2016
#37689: Issues with utf8mb4 collation and the 4.6 update
-----------------------------------+--------------------------
Reporter: Hristo Sg | Owner: pento
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.6.1
Component: Database | Version: 4.6
Severity: normal | Resolution: fixed
Keywords: has-patch fixed-major | Focuses: performance
-----------------------------------+--------------------------
Changes (by pento):
* status: reopened => closed
* resolution: => fixed
Comment:
In [changeset:"38442"]:
{{{
#!CommitTicketReference repository="" revision="38442"
Database: Don't force an unsupported character set that previously
would've silently failed.
[37320] corrected some behaviour in how PHP and MySQL character sets are
matched up. This was correct, but had the side effect of causing some
incorrectly configured sites to start failing.
Prior to [37320], if `DB_CHARSET` was set to `utf8mb4`, but the PHP
version didn't support `utf8mb4`, it would fall back to the default
character set - usually `latin1`. After [37320], the `SET NAMES` query
would force MySQL to treat the connection character set as `utf8mb4`, even
if PHP wasn't able to understand it.
By checking if `mysqli_set_charset()` succeeded, we can simulate the old
behaviour, while maintaining the fix in [37320].
Merge of [38441] to the 4.6 branch.
Props danielkanchev fo helping to diagnose this issue.
Fixes #37689.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37689#comment:22>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list