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
e43f49a4
Commit
e43f49a4
authored
Mar 16, 2006
by
acurtis@xiphis.org
Browse files
Options
Browse Files
Download
Plain Diff
Merge xiphis.org:/home/antony/work2/p1-bug14575.1
into xiphis.org:/home/antony/work2/p1-bug14575.1-mrg2
parents
8cb582cf
e0df8ef9
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
2 deletions
+24
-2
include/config-win.h
include/config-win.h
+2
-2
mysql-test/r/subselect.result
mysql-test/r/subselect.result
+7
-0
mysql-test/t/subselect.test
mysql-test/t/subselect.test
+7
-0
sql/sql_select.cc
sql/sql_select.cc
+8
-0
No files found.
include/config-win.h
View file @
e43f49a4
...
@@ -429,8 +429,8 @@ inline double ulonglong2double(ulonglong value)
...
@@ -429,8 +429,8 @@ inline double ulonglong2double(ulonglong value)
#define HAVE_RTREE_KEYS 1
#define HAVE_RTREE_KEYS 1
#define HAVE_ROW_BASED_REPLICATION 1
#define HAVE_ROW_BASED_REPLICATION 1
/* #undef HAVE_OPENSSL */
#define HAVE_OPENSSL 1
/* #undef HAVE_YASSL */
#define HAVE_YASSL 1
/* Define charsets you want */
/* Define charsets you want */
/* #undef HAVE_CHARSET_armscii8 */
/* #undef HAVE_CHARSET_armscii8 */
...
...
mysql-test/r/subselect.result
View file @
e43f49a4
...
@@ -3156,3 +3156,10 @@ id select_type table type possible_keys key key_len ref rows Extra
...
@@ -3156,3 +3156,10 @@ id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY t1 ALL NULL NULL NULL NULL 9 Using where
1 PRIMARY t1 ALL NULL NULL NULL NULL 9 Using where
2 DEPENDENT SUBQUERY t1 index NULL a 8 NULL 9 Using filesort
2 DEPENDENT SUBQUERY t1 index NULL a 8 NULL 9 Using filesort
DROP TABLE t1;
DROP TABLE t1;
create table t1( f1 int,f2 int);
insert into t1 values (1,1),(2,2);
select tt.t from (select 'crash1' as t, f2 from t1) as tt left join t1 on tt.t = 'crash2' and tt.f2 = t1.f2 where tt.t = 'crash1';
t
crash1
crash1
drop table t1;
mysql-test/t/subselect.test
View file @
e43f49a4
...
@@ -2067,3 +2067,10 @@ SELECT * FROM t1 WHERE (a,b) = ANY (SELECT a, max(b) FROM t1 GROUP BY a);
...
@@ -2067,3 +2067,10 @@ SELECT * FROM t1 WHERE (a,b) = ANY (SELECT a, max(b) FROM t1 GROUP BY a);
DROP
TABLE
t1
;
DROP
TABLE
t1
;
#
# Bug#17366: Unchecked Item_int results in server crash
#
create
table
t1
(
f1
int
,
f2
int
);
insert
into
t1
values
(
1
,
1
),(
2
,
2
);
select
tt
.
t
from
(
select
'crash1'
as
t
,
f2
from
t1
)
as
tt
left
join
t1
on
tt
.
t
=
'crash2'
and
tt
.
f2
=
t1
.
f2
where
tt
.
t
=
'crash1'
;
drop
table
t1
;
sql/sql_select.cc
View file @
e43f49a4
...
@@ -7114,7 +7114,10 @@ static Item *eliminate_item_equal(COND *cond, COND_EQUAL *upper_levels,
...
@@ -7114,7 +7114,10 @@ static Item *eliminate_item_equal(COND *cond, COND_EQUAL *upper_levels,
if
(
!
cond
)
if
(
!
cond
)
cond
=
new
Item_cond_and
(
eq_list
);
cond
=
new
Item_cond_and
(
eq_list
);
else
else
{
DBUG_ASSERT
(
cond
->
type
()
==
Item
::
COND_ITEM
);
((
Item_cond
*
)
cond
)
->
add_at_head
(
&
eq_list
);
((
Item_cond
*
)
cond
)
->
add_at_head
(
&
eq_list
);
}
cond
->
quick_fix_field
();
cond
->
quick_fix_field
();
cond
->
update_used_tables
();
cond
->
update_used_tables
();
...
@@ -7199,6 +7202,11 @@ static COND* substitute_for_best_equal_field(COND *cond,
...
@@ -7199,6 +7202,11 @@ static COND* substitute_for_best_equal_field(COND *cond,
while
((
item_equal
=
it
++
))
while
((
item_equal
=
it
++
))
{
{
cond
=
eliminate_item_equal
(
cond
,
cond_equal
->
upper_levels
,
item_equal
);
cond
=
eliminate_item_equal
(
cond
,
cond_equal
->
upper_levels
,
item_equal
);
// This occurs when eliminate_item_equal() founds that cond is
// always false and substitues it with Item_int 0.
// Due to this, value of item_equal will be 0, so just return it.
if
(
cond
->
type
()
!=
Item
::
COND_ITEM
)
break
;
}
}
}
}
}
}
...
...
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