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
6aef4237
Commit
6aef4237
authored
Sep 22, 2002
by
monty@mashka.mysql.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed bug in previous patch when using a libc with static nss
parent
8a5ef8dc
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
7 deletions
+26
-7
client/mysql.cc
client/mysql.cc
+3
-3
configure.in
configure.in
+4
-1
mysql-test/t/rpl_rotate_logs.test
mysql-test/t/rpl_rotate_logs.test
+1
-1
sql/sql_acl.cc
sql/sql_acl.cc
+18
-2
No files found.
client/mysql.cc
View file @
6aef4237
...
...
@@ -40,7 +40,7 @@
#include <signal.h>
#include <violite.h>
const
char
*
VER
=
"12.1
3
"
;
const
char
*
VER
=
"12.1
4
"
;
/* Don't try to make a nice table if the data is too big */
#define MAX_COLUMN_LENGTH 1024
...
...
@@ -476,7 +476,8 @@ static struct my_option my_long_options[] =
{
"ignore-space"
,
'i'
,
"Ignore space after function names."
,
0
,
0
,
0
,
GET_NO_ARG
,
NO_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
{
"local-infile"
,
OPT_LOCAL_INFILE
,
"Enable/disable LOAD DATA LOCAL INFILE."
,
0
,
0
,
0
,
GET_STR
,
OPT_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
(
gptr
*
)
&
opt_local_infile
,
(
gptr
*
)
&
opt_local_infile
,
0
,
GET_BOOL
,
OPT_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
{
"no-beep"
,
'b'
,
"Turn off beep on error."
,
(
gptr
*
)
&
opt_nobeep
,
(
gptr
*
)
&
opt_nobeep
,
0
,
GET_BOOL
,
NO_ARG
,
0
,
0
,
0
,
0
,
0
,
0
},
{
"host"
,
'h'
,
"Connect to host."
,
(
gptr
*
)
&
current_host
,
...
...
@@ -609,7 +610,6 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
break
;
case
OPT_LOCAL_INFILE
:
using_opt_local_infile
=
1
;
opt_local_infile
=
test
(
!
argument
||
atoi
(
argument
)
>
0
);
break
;
case
OPT_TEE
:
if
(
argument
==
disabled_my_option
)
...
...
configure.in
View file @
6aef4237
...
...
@@ -454,6 +454,8 @@ fi
NOINST_LDFLAGS
=
static_nss
=
""
STATIC_NSS_FLAGS
=
""
OTHER_LIBC_LIB
=
""
AC_ARG_WITH
(
other-libc,
[
--with-other-libc
=
DIR Link against libc and other standard libraries
installed
in
the specified non-standard location
...
...
@@ -479,6 +481,7 @@ AC_ARG_WITH(other-libc,
# we need special flags, but we will have to add those later
STATIC_NSS_FLAGS
=
"-Wl,--start-group -lc -lnss_files -lnss_dns -lresolv
\
-Wl,--end-group"
OTHER_LIBC_LIB
=
"-L
$other_libc_lib
"
static_nss
=
1
else
# this is a dirty hack. We if we detect static nss glibc in the special
...
...
@@ -2390,7 +2393,7 @@ fi
if
test
"
$static_nss
"
=
"1"
then
LDFLAGS
=
"
$LDFLAGS
-static
-L
$other_libc_lib
"
LDFLAGS
=
"
$LDFLAGS
-static
$OTHER_LIBC_LIB
"
LIBS
=
"
$LIBS
$STATIC_NSS_FLAGS
"
fi
...
...
mysql-test/t/rpl_rotate_logs.test
View file @
6aef4237
...
...
@@ -139,7 +139,7 @@ select count(*) from t3 where n >= 4;
unlock
tables
;
#clean up
connection
master
;
drop
table
if
exists
t1
,
t2
,
t3
;
drop
table
if
exists
t1
,
t2
,
t3
,
t4
;
save_master_pos
;
connection
slave
;
sync_with_master
;
sql/sql_acl.cc
View file @
6aef4237
...
...
@@ -741,11 +741,25 @@ static void acl_update_db(const char *user, const char *host, const char *db,
}
/*
Insert a user/db/host combination into the global acl_cache
SYNOPSIS
acl_insert_db()
user User name
host Host name
db Database name
privileges Bitmap of privileges
NOTES
acl_cache->lock must be locked when calling this
*/
static
void
acl_insert_db
(
const
char
*
user
,
const
char
*
host
,
const
char
*
db
,
ulong
privileges
)
{
ACL_DB
acl_db
;
/* The acl_cache mutex is locked by mysql_grant */
safe_mutex_assert_owner
(
&
acl_cache
->
lock
);
acl_db
.
user
=
strdup_root
(
&
mem
,
user
);
update_hostname
(
&
acl_db
.
host
,
strdup_root
(
&
mem
,
host
));
acl_db
.
db
=
strdup_root
(
&
mem
,
db
);
...
...
@@ -1217,6 +1231,7 @@ static int replace_user_table(THD *thd, TABLE *table, const LEX_USER &combo,
char
*
password
,
empty_string
[
1
];
char
what
=
(
revoke_grant
)
?
'N'
:
'Y'
;
DBUG_ENTER
(
"replace_user_table"
);
safe_mutex_assert_owner
(
&
acl_cache
->
lock
);
password
=
empty_string
;
empty_string
[
0
]
=
0
;
...
...
@@ -1240,7 +1255,6 @@ static int replace_user_table(THD *thd, TABLE *table, const LEX_USER &combo,
{
if
(
!
create_user
)
{
THD
*
thd
=
current_thd
;
if
(
what
==
'N'
)
my_printf_error
(
ER_NONEXISTING_GRANT
,
ER
(
ER_NONEXISTING_GRANT
),
MYF
(
0
),
combo
.
user
.
str
,
combo
.
host
.
str
);
...
...
@@ -1621,6 +1635,7 @@ static GRANT_TABLE *table_hash_search(const char *host,const char* ip,
char
helping
[
NAME_LEN
*
2
+
USERNAME_LENGTH
+
3
];
uint
len
;
GRANT_TABLE
*
grant_table
,
*
found
=
0
;
safe_mutex_assert_owner
(
&
LOCK_grant
);
len
=
(
uint
)
(
strmov
(
strmov
(
strmov
(
helping
,
user
)
+
1
,
db
)
+
1
,
tname
)
-
helping
)
+
1
;
for
(
grant_table
=
(
GRANT_TABLE
*
)
hash_search
(
&
hash_tables
,(
byte
*
)
helping
,
...
...
@@ -1828,6 +1843,7 @@ static int replace_table_table(THD *thd, GRANT_TABLE *grant_table,
int
error
=
0
;
ulong
store_table_rights
,
store_col_rights
;
DBUG_ENTER
(
"replace_table_table"
);
safe_mutex_assert_owner
(
&
LOCK_grant
);
strxmov
(
grantor
,
thd
->
user
,
"@"
,
thd
->
host_or_ip
,
NullS
);
...
...
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