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
50afa94d
Commit
50afa94d
authored
Nov 17, 2005
by
guilhem@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge gbichot@bk-internal.mysql.com:/home/bk/mysql-5.1-new
into mysql.com:/home/mysql_src/mysql-5.1
parents
2982de9a
2c8d2ebe
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
19 deletions
+31
-19
sql/rpl_filter.cc
sql/rpl_filter.cc
+24
-17
sql/rpl_filter.h
sql/rpl_filter.h
+7
-2
No files found.
sql/rpl_filter.cc
View file @
50afa94d
...
...
@@ -449,9 +449,11 @@ Rpl_filter::free_string_array(DYNAMIC_ARRAY *a)
*/
void
Rpl_filter
::
table_rule_ent_hash_to_str
(
String
*
s
,
HASH
*
h
)
Rpl_filter
::
table_rule_ent_hash_to_str
(
String
*
s
,
HASH
*
h
,
bool
inited
)
{
s
->
length
(
0
);
if
(
inited
)
{
for
(
uint
i
=
0
;
i
<
h
->
records
;
i
++
)
{
TABLE_RULE_ENT
*
e
=
(
TABLE_RULE_ENT
*
)
hash_element
(
h
,
i
);
...
...
@@ -459,13 +461,17 @@ Rpl_filter::table_rule_ent_hash_to_str(String* s, HASH* h)
s
->
append
(
','
);
s
->
append
(
e
->
db
,
e
->
key_len
);
}
}
}
void
Rpl_filter
::
table_rule_ent_dynamic_array_to_str
(
String
*
s
,
DYNAMIC_ARRAY
*
a
)
Rpl_filter
::
table_rule_ent_dynamic_array_to_str
(
String
*
s
,
DYNAMIC_ARRAY
*
a
,
bool
inited
)
{
s
->
length
(
0
);
if
(
inited
)
{
for
(
uint
i
=
0
;
i
<
a
->
elements
;
i
++
)
{
TABLE_RULE_ENT
*
e
;
...
...
@@ -474,34 +480,35 @@ Rpl_filter::table_rule_ent_dynamic_array_to_str(String* s, DYNAMIC_ARRAY* a)
s
->
append
(
','
);
s
->
append
(
e
->
db
,
e
->
key_len
);
}
}
}
void
Rpl_filter
::
get_do_table
(
String
*
str
)
{
table_rule_ent_hash_to_str
(
str
,
&
do_table
);
table_rule_ent_hash_to_str
(
str
,
&
do_table
,
do_table_inited
);
}
void
Rpl_filter
::
get_ignore_table
(
String
*
str
)
{
table_rule_ent_hash_to_str
(
str
,
&
ignore_table
);
table_rule_ent_hash_to_str
(
str
,
&
ignore_table
,
ignore_table_inited
);
}
void
Rpl_filter
::
get_wild_do_table
(
String
*
str
)
{
table_rule_ent_dynamic_array_to_str
(
str
,
&
wild_do_table
);
table_rule_ent_dynamic_array_to_str
(
str
,
&
wild_do_table
,
wild_do_table_inited
);
}
void
Rpl_filter
::
get_wild_ignore_table
(
String
*
str
)
{
table_rule_ent_dynamic_array_to_str
(
str
,
&
wild_ignore_table
);
table_rule_ent_dynamic_array_to_str
(
str
,
&
wild_ignore_table
,
wild_ignore_table_inited
);
}
...
...
sql/rpl_filter.h
View file @
50afa94d
...
...
@@ -87,10 +87,15 @@ private:
void
free_string_array
(
DYNAMIC_ARRAY
*
a
);
void
table_rule_ent_hash_to_str
(
String
*
s
,
HASH
*
h
);
void
table_rule_ent_dynamic_array_to_str
(
String
*
s
,
DYNAMIC_ARRAY
*
a
);
void
table_rule_ent_hash_to_str
(
String
*
s
,
HASH
*
h
,
bool
inited
);
void
table_rule_ent_dynamic_array_to_str
(
String
*
s
,
DYNAMIC_ARRAY
*
a
,
bool
inited
);
TABLE_RULE_ENT
*
find_wild
(
DYNAMIC_ARRAY
*
a
,
const
char
*
key
,
int
len
);
/*
Those 4 structures below are uninitialized memory unless the
corresponding *_inited variables are "true".
*/
HASH
do_table
;
HASH
ignore_table
;
DYNAMIC_ARRAY
wild_do_table
;
...
...
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