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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
7a6479d1
Commit
7a6479d1
authored
Nov 14, 2012
by
Jimmy Yang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Bug #14753402 - FAILING ASSERTION: LEN == IFIELD->FIXED_LEN
rb://1411
approved by Marko
parent
fcf17c39
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
49 additions
and
3 deletions
+49
-3
mysql-test/suite/innodb/r/innodb_bug14753402.result
mysql-test/suite/innodb/r/innodb_bug14753402.result
+5
-0
mysql-test/suite/innodb/t/innodb_bug14753402.test
mysql-test/suite/innodb/t/innodb_bug14753402.test
+13
-0
storage/innobase/rem/rem0rec.c
storage/innobase/rem/rem0rec.c
+20
-2
storage/innobase/row/row0merge.c
storage/innobase/row/row0merge.c
+11
-1
No files found.
mysql-test/suite/innodb/r/innodb_bug14753402.result
0 → 100644
View file @
7a6479d1
CREATE TABLE bug14753402(a34 INT, col8953 NATIONAL CHAR(231) NOT NULL)
ENGINE=INNODB ROW_FORMAT=REDUNDANT;
INSERT INTO bug14753402 VALUES(1, 'aa');
CREATE INDEX idx1 ON bug14753402(col8953(165));
DROP TABLE bug14753402;
mysql-test/suite/innodb/t/innodb_bug14753402.test
0 → 100644
View file @
7a6479d1
#
# Test Bug 14753402 - FAILING ASSERTION: LEN == IFIELD->FIXED_LEN
#
--
source
include
/
have_innodb
.
inc
CREATE
TABLE
bug14753402
(
a34
INT
,
col8953
NATIONAL
CHAR
(
231
)
NOT
NULL
)
ENGINE
=
INNODB
ROW_FORMAT
=
REDUNDANT
;
INSERT
INTO
bug14753402
VALUES
(
1
,
'aa'
);
CREATE
INDEX
idx1
ON
bug14753402
(
col8953
(
165
));
DROP
TABLE
bug14753402
;
storage/innobase/rem/rem0rec.c
View file @
7a6479d1
...
...
@@ -819,10 +819,19 @@ rec_get_converted_size_comp_prefix(
it is 128 or more, or when the field is stored externally. */
if
(
field
->
fixed_len
)
{
ut_ad
(
len
==
field
->
fixed_len
);
#ifdef UNIV_DEBUG
ulint
mbminlen
=
DATA_MBMINLEN
(
col
->
mbminmaxlen
);
ulint
mbmaxlen
=
DATA_MBMAXLEN
(
col
->
mbminmaxlen
);
ut_ad
(
len
<=
field
->
fixed_len
);
ut_ad
(
!
mbmaxlen
||
len
>=
mbminlen
*
(
field
->
fixed_len
/
mbmaxlen
));
/* dict_index_add_col() should guarantee this */
ut_ad
(
!
field
->
prefix_len
||
field
->
fixed_len
==
field
->
prefix_len
);
#endif
/* UNIV_DEBUG */
}
else
if
(
dfield_is_ext
(
&
fields
[
i
]))
{
ut_ad
(
col
->
len
>=
256
||
col
->
mtype
==
DATA_BLOB
);
extra_size
+=
2
;
...
...
@@ -1169,8 +1178,17 @@ rec_convert_dtuple_to_rec_comp(
0..127. The length will be encoded in two bytes when
it is 128 or more, or when the field is stored externally. */
if
(
fixed_len
)
{
ut_ad
(
len
==
fixed_len
);
#ifdef UNIV_DEBUG
ulint
mbminlen
=
DATA_MBMINLEN
(
ifield
->
col
->
mbminmaxlen
);
ulint
mbmaxlen
=
DATA_MBMAXLEN
(
ifield
->
col
->
mbminmaxlen
);
ut_ad
(
len
<=
fixed_len
);
ut_ad
(
!
mbmaxlen
||
len
>=
mbminlen
*
(
fixed_len
/
mbmaxlen
));
ut_ad
(
!
dfield_is_ext
(
field
));
#endif
/* UNIV_DEBUG */
}
else
if
(
dfield_is_ext
(
field
))
{
ut_ad
(
ifield
->
col
->
len
>=
256
||
ifield
->
col
->
mtype
==
DATA_BLOB
);
...
...
storage/innobase/row/row0merge.c
View file @
7a6479d1
...
...
@@ -347,8 +347,18 @@ row_merge_buf_add(
ut_ad
(
len
<=
col
->
len
||
col
->
mtype
==
DATA_BLOB
);
if
(
ifield
->
fixed_len
)
{
ut_ad
(
len
==
ifield
->
fixed_len
);
#ifdef UNIV_DEBUG
ulint
mbminlen
=
DATA_MBMINLEN
(
col
->
mbminmaxlen
);
ulint
mbmaxlen
=
DATA_MBMAXLEN
(
col
->
mbminmaxlen
);
/* len should be between size calcualted base on
mbmaxlen and mbminlen */
ut_ad
(
len
<=
ifield
->
fixed_len
);
ut_ad
(
!
mbmaxlen
||
len
>=
mbminlen
*
(
ifield
->
fixed_len
/
mbmaxlen
));
ut_ad
(
!
dfield_is_ext
(
field
));
#endif
/* UNIV_DEBUG */
}
else
if
(
dfield_is_ext
(
field
))
{
extra_size
+=
2
;
}
else
if
(
len
<
128
...
...
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