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
2e7e89d6
Commit
2e7e89d6
authored
Jun 08, 2022
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup: move the check out of the loop
parent
124326d8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
10 deletions
+9
-10
sql/sql_show.cc
sql/sql_show.cc
+9
-10
No files found.
sql/sql_show.cc
View file @
2e7e89d6
...
...
@@ -6990,19 +6990,18 @@ static int get_check_constraints_record(THD *thd, TABLE_LIST *tables,
#ifndef NO_EMBEDDED_ACCESS_CHECKS
TABLE_LIST
table_acl_check
;
bzero
((
char
*
)
&
table_acl_check
,
sizeof
(
table_acl_check
));
if
(
!
(
thd
->
col_access
&
TABLE_ACLS
))
{
table_acl_check
.
db
=
*
db_name
;
table_acl_check
.
table_name
=
*
table_name
;
table_acl_check
.
grant
.
privilege
=
thd
->
col_access
;
if
(
check_grant
(
thd
,
TABLE_ACLS
,
&
table_acl_check
,
FALSE
,
1
,
TRUE
))
DBUG_RETURN
(
res
);
}
#endif
for
(
uint
i
=
0
;
i
<
tables
->
table
->
s
->
table_check_constraints
;
i
++
)
{
#ifndef NO_EMBEDDED_ACCESS_CHECKS
if
(
!
(
thd
->
col_access
&
TABLE_ACLS
))
{
table_acl_check
.
db
=
*
db_name
;
table_acl_check
.
table_name
=
*
table_name
;
table_acl_check
.
grant
.
privilege
=
thd
->
col_access
;
if
(
check_grant
(
thd
,
TABLE_ACLS
,
&
table_acl_check
,
FALSE
,
1
,
TRUE
))
continue
;
}
#endif
Virtual_column_info
*
check
=
tables
->
table
->
check_constraints
[
i
];
table
->
field
[
0
]
->
store
(
STRING_WITH_LEN
(
"def"
),
system_charset_info
);
table
->
field
[
3
]
->
store
(
check
->
name
.
str
,
check
->
name
.
length
,
...
...
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