Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
eb140423
Commit
eb140423
authored
Dec 20, 2017
by
Oleksandr Byelkin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-14613: Assertion `fixed == 0' failed in Item_func::fix_fields
fix_fields calls fixed.
parent
8d70097c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
2 deletions
+40
-2
mysql-test/r/func_misc.result
mysql-test/r/func_misc.result
+15
-0
mysql-test/t/func_misc.test
mysql-test/t/func_misc.test
+21
-0
sql/item.cc
sql/item.cc
+4
-2
No files found.
mysql-test/r/func_misc.result
View file @
eb140423
...
...
@@ -1523,5 +1523,20 @@ str str1 b c
::10.0.5.9 ::10.0.5.9 1 0
DROP TABLE t1;
#
# MDEV-14613: Assertion `fixed == 0' failed in Item_func::fix_fields
#
CREATE TABLE `t1` (
`numgtfmt` char(10) COLLATE utf8_bin NOT NULL
) DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
create view v1(numgtfmt)
as
select 'x' from t1
union
select 'x' from t1 ;
SELECT * FROM v1 WHERE numgtfmt = NAME_CONST('wnumgtfmt',_utf8'QEDITIONS' COLLATE 'utf8_bin');
numgtfmt
DROP VIEW v1;
DROP TABLE t1;
#
# End of 10.2 tests
#
mysql-test/t/func_misc.test
View file @
eb140423
...
...
@@ -1152,6 +1152,27 @@ INSERT INTO t1 (str) VALUES ('::FFFF:192.168.0.1'),('::10.0.5.9');
SELECT
str
,
str1
,
b
,
c
FROM
t1
;
DROP
TABLE
t1
;
--
echo
#
--
echo
# MDEV-14613: Assertion `fixed == 0' failed in Item_func::fix_fields
--
echo
#
CREATE
TABLE
`t1`
(
`numgtfmt`
char
(
10
)
COLLATE
utf8_bin
NOT
NULL
)
DEFAULT
CHARSET
=
utf8
COLLATE
=
utf8_bin
;
create
view
v1
(
numgtfmt
)
as
select
'x'
from
t1
union
select
'x'
from
t1
;
SELECT
*
FROM
v1
WHERE
numgtfmt
=
NAME_CONST
(
'wnumgtfmt'
,
_utf8
'QEDITIONS'
COLLATE
'utf8_bin'
);
# Cleanup
DROP
VIEW
v1
;
DROP
TABLE
t1
;
--
echo
#
--
echo
# End of 10.2 tests
--
echo
#
sql/item.cc
View file @
eb140423
...
...
@@ -1814,8 +1814,10 @@ bool Item_name_const::fix_fields(THD *thd, Item **ref)
String
s
(
buf
,
sizeof
(
buf
),
&
my_charset_bin
);
s
.
length
(
0
);
if
(
value_item
->
fix_fields
(
thd
,
&
value_item
)
||
name_item
->
fix_fields
(
thd
,
&
name_item
)
||
if
((
!
value_item
->
fixed
&&
value_item
->
fix_fields
(
thd
,
&
value_item
))
||
(
!
name_item
->
fixed
&&
name_item
->
fix_fields
(
thd
,
&
name_item
))
||
!
value_item
->
const_item
()
||
!
name_item
->
const_item
()
||
!
(
item_name
=
name_item
->
val_str
(
&
s
)))
// Can't have a NULL name
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment