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
f113a7fd
Commit
f113a7fd
authored
Apr 18, 2001
by
monty@donna.mysql.fi
Browse files
Options
Browse Files
Download
Plain Diff
merge
parents
821fa224
bc6fd0ac
Changes
14
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
154 additions
and
54 deletions
+154
-54
Docs/manual.texi
Docs/manual.texi
+63
-38
acconfig.h
acconfig.h
+6
-0
acinclude.m4
acinclude.m4
+36
-0
configure.in
configure.in
+3
-2
innobase/os/os0thread.c
innobase/os/os0thread.c
+5
-1
mysql-test/include/have_default_master.inc
mysql-test/include/have_default_master.inc
+0
-3
mysql-test/r/have_default_master.require
mysql-test/r/have_default_master.require
+0
-2
mysql-test/r/lock.result
mysql-test/r/lock.result
+4
-0
mysql-test/t/lock.test
mysql-test/t/lock.test
+32
-0
mysql-test/t/rpl000014.test
mysql-test/t/rpl000014.test
+0
-1
mysql-test/t/rpl000015.test
mysql-test/t/rpl000015.test
+0
-1
mysql-test/t/rpl000016.test
mysql-test/t/rpl000016.test
+0
-1
sql/ha_myisam.cc
sql/ha_myisam.cc
+4
-2
sql/sql_select.cc
sql/sql_select.cc
+1
-3
No files found.
Docs/manual.texi
View file @
f113a7fd
This diff is collapsed.
Click to expand it.
acconfig.h
View file @
f113a7fd
...
@@ -114,6 +114,12 @@
...
@@ -114,6 +114,12 @@
/* pthread_attr_setscope */
/* pthread_attr_setscope */
#undef HAVE_PTHREAD_ATTR_SETSCOPE
#undef HAVE_PTHREAD_ATTR_SETSCOPE
/* pthread_yield that doesn't take any arguments */
#undef HAVE_PTHREAD_YIELD_ZERO_ARG
/* pthread_yield function with one argument */
#undef HAVE_PTHREAD_YIELD_ONE_ARG
/* POSIX readdir_r */
/* POSIX readdir_r */
#undef HAVE_READDIR_R
#undef HAVE_READDIR_R
...
...
acinclude.m4
View file @
f113a7fd
...
@@ -196,6 +196,42 @@ then
...
@@ -196,6 +196,42 @@ then
fi
fi
])
])
AC_DEFUN(MYSQL_PTHREAD_YIELD,
[AC_CACHE_CHECK([if pthread_yield takes zero arguments], ac_cv_pthread_yield_zero_arg,
[AC_TRY_COMPILE([#define _GNU_SOURCE
#include <pthread.h>
#ifdef __cplusplus
extern "C"
#endif
],
[
pthread_yield();
], ac_cv_pthread_yield_zero_arg=yes, ac_cv_pthread_yield_zero_arg=yeso)])
if test "$ac_cv_pthread_yield_zero_arg" = "yes"
then
AC_DEFINE(HAVE_PTHREAD_YIELD_ZERO_ARG)
fi
]
[AC_CACHE_CHECK([if pthread_yield takes 1 argument], ac_cv_pthread_yield_one_arg,
[AC_TRY_COMPILE([#define _GNU_SOURCE
#include <pthread.h>
#ifdef __cplusplus
extern "C"
#endif
],
[
pthread_yield(0);
], ac_cv_pthread_yield_one_arg=yes, ac_cv_pthread_yield_one_arg=no)])
if test "$ac_cv_pthread_yield_one_arg" = "yes"
then
AC_DEFINE(HAVE_PTHREAD_YIELD_ONE_ARG)
fi
]
)
#---END:
#---END:
AC_DEFUN(MYSQL_CHECK_FP_EXCEPT,
AC_DEFUN(MYSQL_CHECK_FP_EXCEPT,
...
...
configure.in
View file @
f113a7fd
...
@@ -1293,10 +1293,11 @@ MYSQL_CXX_BOOL
...
@@ -1293,10 +1293,11 @@ MYSQL_CXX_BOOL
MYSQL_CHECK_LONGLONG_TO_FLOAT
MYSQL_CHECK_LONGLONG_TO_FLOAT
if
test
"
$ac_cv_conv_longlong_to_float
"
!=
"yes"
if
test
"
$ac_cv_conv_longlong_to_float
"
!=
"yes"
then
then
AC_MSG_ERROR
([
Your compiler can
'
t convert a longlong value to a float!
AC_MSG_ERROR
([
Your compiler can
no
t convert a longlong value to a float!
If you are using gcc 2.8.# you should upgrade to egcs 1.0.3 or newer and try
If you are using gcc 2.8.# you should upgrade to egcs 1.0.3 or newer and try
again]
)
;
again]
)
;
fi
fi
MYSQL_PTHREAD_YIELD
######################################################################
######################################################################
# For readline-4.0 (We simply move the mimimum amount of stuff from
# For readline-4.0 (We simply move the mimimum amount of stuff from
...
@@ -1353,7 +1354,7 @@ AC_CHECK_FUNCS(alarm bmove \
...
@@ -1353,7 +1354,7 @@ AC_CHECK_FUNCS(alarm bmove \
sigset sigthreadmask pthread_sigmask pthread_setprio pthread_setprio_np
\
sigset sigthreadmask pthread_sigmask pthread_setprio pthread_setprio_np
\
pthread_setschedparam pthread_attr_setprio pthread_attr_setschedparam
\
pthread_setschedparam pthread_attr_setprio pthread_attr_setschedparam
\
pthread_attr_create pthread_getsequence_np pthread_attr_setstacksize
\
pthread_attr_create pthread_getsequence_np pthread_attr_setstacksize
\
pthread_condattr_create rwlock_init pthread_rwlock_rdlock
pthread_yield
\
pthread_condattr_create rwlock_init pthread_rwlock_rdlock
\
fchmod getpass getpassphrase initgroups mlockall
)
fchmod getpass getpassphrase initgroups mlockall
)
# Sanity check: We chould not have any fseeko symbol unless
# Sanity check: We chould not have any fseeko symbol unless
...
...
innobase/os/os0thread.c
View file @
f113a7fd
...
@@ -138,7 +138,11 @@ os_thread_yield(void)
...
@@ -138,7 +138,11 @@ os_thread_yield(void)
#if defined(__WIN__)
#if defined(__WIN__)
Sleep
(
0
);
Sleep
(
0
);
#elif (defined(HAVE_SCHED_YIELD) && defined(HAVE_SCHED_H))
#elif (defined(HAVE_SCHED_YIELD) && defined(HAVE_SCHED_H))
sched_yield
();
sched_yield
();
#elif defined(HAVE_PTHREAD_YIELD_ZERO_ARG)
pthread_yield
();
#elif defined(HAVE_PTHREAD_YIELD_ONE_ARG)
pthread_yield
(
0
);
#else
#else
os_thread_sleep
(
0
);
os_thread_sleep
(
0
);
#endif
#endif
...
...
mysql-test/include/have_default_master.inc
deleted
100644 → 0
View file @
821fa224
--
require
r
/
have_default_master
.
require
connection
master
;
show
variables
like
"port"
;
mysql-test/r/have_default_master.require
deleted
100644 → 0
View file @
821fa224
Variable_name Value
port 9306
mysql-test/r/lock.result
View file @
f113a7fd
dummy1 count(distinct id)
dummy1 count(distinct id)
NULL 1
NULL 1
Table Op Msg_type Msg_text
test.t1 check status OK
Table Op Msg_type Msg_text
test.t2 check error Table 't2' was not locked with LOCK TABLES
mysql-test/t/lock.test
View file @
f113a7fd
...
@@ -21,3 +21,35 @@ LOCK TABLE t1 WRITE,t2 write;
...
@@ -21,3 +21,35 @@ LOCK TABLE t1 WRITE,t2 write;
insert
into
t2
SELECT
*
from
t1
;
insert
into
t2
SELECT
*
from
t1
;
update
t1
set
id
=
1
where
id
=-
1
;
update
t1
set
id
=
1
where
id
=-
1
;
drop
table
t1
,
t2
;
drop
table
t1
,
t2
;
#
# Check bug with INSERT ... SELECT with lock tables
#
CREATE
TABLE
t1
(
index1
smallint
(
6
)
default
NULL
,
nr
smallint
(
6
)
default
NULL
,
KEY
index1
(
index1
)
)
TYPE
=
MyISAM
;
CREATE
TABLE
t2
(
nr
smallint
(
6
)
default
NULL
,
name
varchar
(
20
)
default
NULL
)
TYPE
=
MyISAM
;
INSERT
INTO
t2
VALUES
(
1
,
'item1'
);
INSERT
INTO
t2
VALUES
(
2
,
'item2'
);
# problem begins here!
lock
tables
t1
write
,
t2
read
;
insert
into
t1
select
1
,
nr
from
t2
where
name
=
'item1'
;
insert
into
t1
select
2
,
nr
from
t2
where
name
=
'item2'
;
unlock
tables
;
check
table
t1
;
# Check error message
lock
tables
t1
write
;
check
table
t2
;
unlock
tables
;
drop
table
t1
,
t2
;
mysql-test/t/rpl000014.test
View file @
f113a7fd
source
include
/
master
-
slave
.
inc
;
source
include
/
master
-
slave
.
inc
;
source
include
/
have_default_master
.
inc
;
connection
master
;
connection
master
;
show
master
status
;
show
master
status
;
save_master_pos
;
save_master_pos
;
...
...
mysql-test/t/rpl000015.test
View file @
f113a7fd
connect
(
master
,
localhost
,
root
,,
test
,
0
,
mysql
-
master
.
sock
);
connect
(
master
,
localhost
,
root
,,
test
,
0
,
mysql
-
master
.
sock
);
connect
(
slave
,
localhost
,
root
,,
test
,
0
,
mysql
-
slave
.
sock
);
connect
(
slave
,
localhost
,
root
,,
test
,
0
,
mysql
-
slave
.
sock
);
source
include
/
have_default_master
.
inc
;
connection
master
;
connection
master
;
reset
master
;
reset
master
;
show
master
status
;
show
master
status
;
...
...
mysql-test/t/rpl000016.test
View file @
f113a7fd
connect
(
master
,
localhost
,
root
,,
test
,
0
,
mysql
-
master
.
sock
);
connect
(
master
,
localhost
,
root
,,
test
,
0
,
mysql
-
master
.
sock
);
connect
(
slave
,
localhost
,
root
,,
test
,
0
,
mysql
-
slave
.
sock
);
connect
(
slave
,
localhost
,
root
,,
test
,
0
,
mysql
-
slave
.
sock
);
source
include
/
have_default_master
.
inc
;
system
cat
/
dev
/
null
>
var
/
slave
-
data
/
master
.
info
;
system
cat
/
dev
/
null
>
var
/
slave
-
data
/
master
.
info
;
system
chmod
000
var
/
slave
-
data
/
master
.
info
;
system
chmod
000
var
/
slave
-
data
/
master
.
info
;
connection
slave
;
connection
slave
;
...
...
sql/ha_myisam.cc
View file @
f113a7fd
...
@@ -533,7 +533,8 @@ int ha_myisam::repair(THD *thd, MI_CHECK ¶m, bool optimize)
...
@@ -533,7 +533,8 @@ int ha_myisam::repair(THD *thd, MI_CHECK ¶m, bool optimize)
VOID
(
fn_format
(
fixed_name
,
file
->
filename
,
""
,
MI_NAME_IEXT
,
VOID
(
fn_format
(
fixed_name
,
file
->
filename
,
""
,
MI_NAME_IEXT
,
4
+
(
param
.
opt_follow_links
?
16
:
0
)));
4
+
(
param
.
opt_follow_links
?
16
:
0
)));
if
(
mi_lock_database
(
file
,
F_WRLCK
))
// Don't lock tables if we have used LOCK TABLE
if
(
!
thd
->
locked_tables
&&
mi_lock_database
(
file
,
F_WRLCK
))
{
{
mi_check_print_error
(
&
param
,
ER
(
ER_CANT_LOCK
),
my_errno
);
mi_check_print_error
(
&
param
,
ER
(
ER_CANT_LOCK
),
my_errno
);
DBUG_RETURN
(
HA_ADMIN_FAILED
);
DBUG_RETURN
(
HA_ADMIN_FAILED
);
...
@@ -615,7 +616,8 @@ int ha_myisam::repair(THD *thd, MI_CHECK ¶m, bool optimize)
...
@@ -615,7 +616,8 @@ int ha_myisam::repair(THD *thd, MI_CHECK ¶m, bool optimize)
update_state_info
(
&
param
,
file
,
0
);
update_state_info
(
&
param
,
file
,
0
);
}
}
thd
->
proc_info
=
old_proc_info
;
thd
->
proc_info
=
old_proc_info
;
mi_lock_database
(
file
,
F_UNLCK
);
if
(
!
thd
->
locked_tables
)
mi_lock_database
(
file
,
F_UNLCK
);
DBUG_RETURN
(
error
?
HA_ADMIN_FAILED
:
DBUG_RETURN
(
error
?
HA_ADMIN_FAILED
:
!
optimize_done
?
HA_ADMIN_ALREADY_DONE
:
HA_ADMIN_OK
);
!
optimize_done
?
HA_ADMIN_ALREADY_DONE
:
HA_ADMIN_OK
);
}
}
...
...
sql/sql_select.cc
View file @
f113a7fd
...
@@ -528,9 +528,7 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds,
...
@@ -528,9 +528,7 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds,
if
(
order
&&
if
(
order
&&
(
join
.
const_tables
==
join
.
tables
||
(
join
.
const_tables
==
join
.
tables
||
test_if_skip_sort_order
(
&
join
.
join_tab
[
join
.
const_tables
],
order
,
test_if_skip_sort_order
(
&
join
.
join_tab
[
join
.
const_tables
],
order
,
(
having
||
group
||
(
group
?
HA_POS_ERROR
:
thd
->
select_limit
))))
join
.
const_tables
!=
join
.
tables
-
1
)
?
HA_POS_ERROR
:
thd
->
select_limit
)))
order
=
0
;
order
=
0
;
select_describe
(
&
join
,
need_tmp
,
select_describe
(
&
join
,
need_tmp
,
(
order
!=
0
&&
(
order
!=
0
&&
...
...
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