Test result for main.gis-rt-precise in MariaDB differs from MySQL. Please verify if there is a real bug here.
Result difference attached. Relevant 5.6 revision:
committer: Nirbhay Choubey <email@example.com>
branch nick: B13813064-5.6
timestamp: Tue 2012-07-17 21:55:25 +0530
Bug#13813064 QUERY USING SPATIAL INDEX RETURNS
Bug#14096685 WITHIN() YIELDS NO RESULTS WHEN
SPATIAL INDEX IS USED
The ST_Contains & Within() functions doesn't
show correct result when executed with spatial
The reason behind this problem is that the spatial
index for Contains and Within class of functions in
MyISAM is implemented in opposite order.
Fixed by adjusting the flag that controls which
implementation to use and item's rev_functype()
for Contains & Within functions.