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
7e80c6e4
Commit
7e80c6e4
authored
Oct 21, 2011
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixes for windows
parent
c0ad2cd8
Changes
31
Hide whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
57 additions
and
145 deletions
+57
-145
extra/yassl/src/timer.cpp
extra/yassl/src/timer.cpp
+1
-1
include/my_base.h
include/my_base.h
+0
-3
include/my_pthread.h
include/my_pthread.h
+0
-15
include/mysql/plugin.h
include/mysql/plugin.h
+3
-3
include/mysql/plugin_auth_common.h
include/mysql/plugin_auth_common.h
+4
-0
include/mysql_com.h
include/mysql_com.h
+3
-0
plugin/auth_dialog/dialog.c
plugin/auth_dialog/dialog.c
+6
-22
plugin/semisync/semisync_master.cc
plugin/semisync/semisync_master.cc
+0
-9
plugin/win_auth_client/CMakeLists.txt
plugin/win_auth_client/CMakeLists.txt
+1
-1
sql/CMakeLists.txt
sql/CMakeLists.txt
+1
-0
sql/mysqld.cc
sql/mysqld.cc
+1
-1
sql/net_serv.cc
sql/net_serv.cc
+1
-1
storage/federated/ha_federated.cc
storage/federated/ha_federated.cc
+12
-1
storage/maria/CMakeLists.txt
storage/maria/CMakeLists.txt
+1
-1
storage/maria/unittest/ma_pagecache_consist.c
storage/maria/unittest/ma_pagecache_consist.c
+1
-1
storage/maria/unittest/ma_pagecache_rwconsist.c
storage/maria/unittest/ma_pagecache_rwconsist.c
+1
-1
storage/maria/unittest/ma_pagecache_rwconsist2.c
storage/maria/unittest/ma_pagecache_rwconsist2.c
+1
-1
storage/maria/unittest/ma_pagecache_single.c
storage/maria/unittest/ma_pagecache_single.c
+1
-1
storage/maria/unittest/ma_test_loghandler_pagecache-t.c
storage/maria/unittest/ma_test_loghandler_pagecache-t.c
+1
-1
storage/oqgraph/CMakeLists.txt
storage/oqgraph/CMakeLists.txt
+3
-4
storage/pbxt/CMakeLists.txt
storage/pbxt/CMakeLists.txt
+1
-2
storage/pbxt/src/datalog_xt.cc
storage/pbxt/src/datalog_xt.cc
+1
-1
storage/pbxt/src/pthread_xt.cc
storage/pbxt/src/pthread_xt.cc
+1
-31
storage/pbxt/src/thread_xt.cc
storage/pbxt/src/thread_xt.cc
+0
-9
storage/sphinx/ha_sphinx.cc
storage/sphinx/ha_sphinx.cc
+1
-3
storage/xtradb/CMakeLists.txt
storage/xtradb/CMakeLists.txt
+1
-1
storage/xtradb/log/log0recv.c
storage/xtradb/log/log0recv.c
+7
-0
storage/xtradb/os/os0file.c
storage/xtradb/os/os0file.c
+2
-14
storage/xtradb/srv/srv0srv.c
storage/xtradb/srv/srv0srv.c
+0
-14
storage/xtradb/srv/srv0start.c
storage/xtradb/srv/srv0start.c
+1
-1
unittest/mytap/CMakeLists.txt
unittest/mytap/CMakeLists.txt
+0
-2
No files found.
extra/yassl/src/timer.cpp
View file @
7e80c6e4
...
...
@@ -24,7 +24,7 @@
#include "timer.hpp"
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
1
#include <windows.h>
#else
#include <sys/time.h>
...
...
include/my_base.h
View file @
7e80c6e4
...
...
@@ -19,8 +19,6 @@
#ifndef _my_base_h
#define _my_base_h
#ifndef stdin
/* Included first in handler */
#define CHSIZE_USED
#include <my_global.h>
#include <my_dir.h>
/* This includes types */
#include <my_sys.h>
...
...
@@ -31,7 +29,6 @@
#define EOVERFLOW 84
#endif
#endif
/* stdin */
#include <my_list.h>
/* The following is bits in the flag parameter to ha_open() */
...
...
include/my_pthread.h
View file @
7e80c6e4
...
...
@@ -91,21 +91,6 @@ struct timespec {
long
tv_nsec
;
};
/**
Compare two timespec structs.
@retval 1 If TS1 ends after TS2.
@retval 0 If TS1 is equal to TS2.
@retval -1 If TS1 ends before TS2.
*/
#define cmp_timespec(TS1, TS2) \
((TS1.tv.i64 > TS2.tv.i64) ? 1 : \
((TS1.tv.i64 < TS2.tv.i64) ? -1 : 0))
int
win_pthread_mutex_trylock
(
pthread_mutex_t
*
mutex
);
int
pthread_create
(
pthread_t
*
,
const
pthread_attr_t
*
,
pthread_handler
,
void
*
);
int
pthread_cond_init
(
pthread_cond_t
*
cond
,
const
pthread_condattr_t
*
attr
);
...
...
include/mysql/plugin.h
View file @
7e80c6e4
...
...
@@ -122,9 +122,9 @@ int PSIZE= sizeof(struct st_mysql_plugin); \
struct st_mysql_plugin DECLS[]= {
#define MARIA_DECLARE_PLUGIN__(NAME, VERSION, PSIZE, DECLS) \
int VERSION= MARIA_PLUGIN_INTERFACE_VERSION;
\
int PSIZE= sizeof(struct st_maria_plugin);
\
struct st_maria_plugin DECLS[]= {
MYSQL_PLUGIN_EXPORT int VERSION= MARIA_PLUGIN_INTERFACE_VERSION;
\
MYSQL_PLUGIN_EXPORT int PSIZE= sizeof(struct st_maria_plugin);
\
MYSQL_PLUGIN_EXPORT
struct st_maria_plugin DECLS[]= {
#else
#define __MYSQL_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS) \
...
...
include/mysql/plugin_auth_common.h
View file @
7e80c6e4
...
...
@@ -15,6 +15,10 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#ifdef _WIN32
#include <windows.h>
#endif
/**
@file
...
...
include/mysql_com.h
View file @
7e80c6e4
...
...
@@ -56,6 +56,9 @@
#define LOCAL_HOST "localhost"
#define LOCAL_HOST_NAMEDPIPE "."
#ifdef _WIN32
#include <ws2tcpip.h>
#endif
#if defined(__WIN__) && !defined( _CUSTOMCONFIG_)
#define MYSQL_NAMEDPIPE "MySQL"
...
...
plugin/auth_dialog/dialog.c
View file @
7e80c6e4
...
...
@@ -24,31 +24,15 @@
asks the user the question, as provided by the server and reports
the answer back to the server. No encryption is involved,
the answers are sent in clear text.
Two examples are provided: two_questions server plugin, that asks
the password and an "Are you sure?" question with a reply "yes, of course".
It demonstrates the usage of "password" (input is hidden) and "ordinary"
(input can be echoed) questions, and how to mark the last question,
to avoid an extra roundtrip.
And three_attempts plugin that gives the user three attempts to enter
a correct password. It shows the situation when a number of questions
is not known in advance.
*/
#if defined (WIN32) && !defined (RTLD_DEFAULT)
# define RTLD_DEFAULT GetModuleHandle(NULL)
#endif
#if !defined (_GNU_SOURCE)
# define _GNU_SOURCE
/* for RTLD_DEFAULT */
#endif
#include <my_global.h>
#include <mysql/client_plugin.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <mysql.h>
#include <dlfcn.h>
#include <string.h>
#if defined (_WIN32)
# define RTLD_DEFAULT GetModuleHandle(NULL)
#endif
/*
This plugin performs a dialog with the user, asking questions and
...
...
plugin/semisync/semisync_master.cc
View file @
7e80c6e4
...
...
@@ -47,11 +47,7 @@ static int getWaitTime(const struct timespec& start_ts);
static
unsigned
long
long
timespec_to_usec
(
const
struct
timespec
*
ts
)
{
#ifndef __WIN__
return
(
unsigned
long
long
)
ts
->
tv_sec
*
TIME_MILLION
+
ts
->
tv_nsec
/
TIME_THOUSAND
;
#else
return
ts
->
tv
.
i64
/
10
;
#endif
/* __WIN__ */
}
/*******************************************************************************
...
...
@@ -678,10 +674,6 @@ int ReplSemiSyncMaster::commitTrx(const char* trx_wait_binlog_name,
}
/* Calcuate the waiting period. */
#ifdef __WIN__
abstime
.
tv
.
i64
=
start_ts
.
tv
.
i64
+
(
__int64
)
wait_timeout_
*
TIME_THOUSAND
*
10
;
abstime
.
max_timeout_msec
=
(
long
)
wait_timeout_
;
#else
unsigned
long
long
diff_nsecs
=
start_ts
.
tv_nsec
+
(
unsigned
long
long
)
wait_timeout_
*
TIME_MILLION
;
abstime
.
tv_sec
=
start_ts
.
tv_sec
;
...
...
@@ -691,7 +683,6 @@ int ReplSemiSyncMaster::commitTrx(const char* trx_wait_binlog_name,
diff_nsecs
-=
TIME_BILLION
;
}
abstime
.
tv_nsec
=
diff_nsecs
;
#endif
/* __WIN__ */
/* In semi-synchronous replication, we wait until the binlog-dump
* thread has received the reply on the relevant binlog segment from the
...
...
plugin/win_auth_client/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -28,7 +28,7 @@ IF(WIN32)
log_client.cc common.cc handshake.cc
)
MYSQL_ADD_PLUGIN
(
authentication_windows_client
${
PLUGIN_SOURCES
}
${
HEADERS
}
LINK_LIBRAR
U
ES Secur32
LINK_LIBRAR
I
ES Secur32
MODULE_ONLY
)
ENDIF
(
WIN32
)
sql/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -100,6 +100,7 @@ TARGET_LINK_LIBRARIES(sql ${MYSQLD_STATIC_PLUGIN_LIBS}
IF
(
WIN32
)
SET
(
MYSQLD_SOURCE main.cc nt_servc.cc nt_servc.h message.rc
)
TARGET_LINK_LIBRARIES
(
sql psapi
)
ELSE
()
SET
(
MYSQLD_SOURCE main.cc
${
DTRACE_PROBES_ALL
}
)
ENDIF
()
...
...
sql/mysqld.cc
View file @
7e80c6e4
...
...
@@ -2753,6 +2753,7 @@ extern "C" char *my_demangle(const char *mangled_name, int *status)
}
#endif
extern
const
char
*
optimizer_switch_names
[];
extern
"C"
sig_handler
handle_segfault
(
int
sig
)
{
...
...
@@ -2859,7 +2860,6 @@ the thread stack. Please read http://dev.mysql.com/doc/mysql/en/linux.html\n\n",
fprintf
(
stderr
,
"Status: %s
\n
"
,
kreason
);
fprintf
(
stderr
,
"Optimizer switch: "
);
extern
const
char
*
optimizer_switch_names
[];
ulonglong
optsw
=
global_system_variables
.
optimizer_switch
;
for
(
uint
i
=
0
;
optimizer_switch_names
[
i
+
1
];
i
++
,
optsw
>>=
1
)
{
...
...
sql/net_serv.cc
View file @
7e80c6e4
...
...
@@ -59,7 +59,7 @@
#define EXTRA_DEBUG_fflush fflush
#else
static
void
inline
EXTRA_DEBUG_fprintf
(...)
{}
static
int
EXTRA_DEBUG_fflush
(...)
{
}
static
int
inline
EXTRA_DEBUG_fflush
(...)
{
return
0
;
}
#endif
#ifdef MYSQL_SERVER
#define MYSQL_SERVER_my_error my_error
...
...
storage/federated/ha_federated.cc
View file @
7e80c6e4
...
...
@@ -3027,8 +3027,19 @@ int ha_federated::delete_all_rows()
}
/*
The idea with handler::store_lock() is the following:
Used to manually truncate the table via a delete of all rows in a table.
*/
int
ha_federated
::
truncate
()
{
return
delete_all_rows
();
}
/* The idea with handler::store_lock() is the following:
The statement decided which locks we should need for the table
for updates/deletes/inserts we get WRITE locks, for SELECT... we get
...
...
storage/maria/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -42,7 +42,7 @@ SET(ARIA_SOURCES ma_init.c ma_open.c ma_extra.c ma_info.c ma_rkey.c
)
MYSQL_ADD_PLUGIN
(
aria
${
ARIA_SOURCES
}
STORAGE_ENGINE
STORAGE_ENGINE
STATIC_ONLY DEFAULT
RECOMPILE_FOR_EMBEDDED
)
TARGET_LINK_LIBRARIES
(
aria myisam
)
...
...
storage/maria/unittest/ma_pagecache_consist.c
View file @
7e80c6e4
...
...
@@ -395,7 +395,7 @@ int main(int argc __attribute__((unused)),
pagecache_file_init
(
file1
,
&
dummy_callback
,
&
dummy_callback
,
&
dummy_fail_callback
,
&
dummy_callback
,
NULL
);
DBUG_PRINT
(
"info"
,
(
"file1: %d"
,
file1
.
file
));
if
(
my_chmod
(
file1_name
,
S_IRWXU
|
S_IRWXG
|
S_IRWXO
,
MYF
(
MY_WME
)))
if
(
my_chmod
(
file1_name
,
0777
,
MYF
(
MY_WME
)))
exit
(
1
);
my_pwrite
(
file1
.
file
,
(
const
uchar
*
)
"test file"
,
9
,
0
,
MYF
(
0
));
...
...
storage/maria/unittest/ma_pagecache_rwconsist.c
View file @
7e80c6e4
...
...
@@ -265,7 +265,7 @@ int main(int argc __attribute__((unused)),
pagecache_file_init
(
file1
,
&
dummy_callback
,
&
dummy_callback
,
&
dummy_fail_callback
,
&
dummy_callback
,
NULL
);
DBUG_PRINT
(
"info"
,
(
"file1: %d"
,
file1
.
file
));
if
(
my_chmod
(
file1_name
,
S_IRWXU
|
S_IRWXG
|
S_IRWXO
,
MYF
(
MY_WME
)))
if
(
my_chmod
(
file1_name
,
0777
,
MYF
(
MY_WME
)))
exit
(
1
);
my_pwrite
(
file1
.
file
,
(
const
uchar
*
)
"test file"
,
9
,
0
,
MYF
(
0
));
...
...
storage/maria/unittest/ma_pagecache_rwconsist2.c
View file @
7e80c6e4
...
...
@@ -261,7 +261,7 @@ int main(int argc __attribute__((unused)),
pagecache_file_init
(
file1
,
&
dummy_callback
,
&
dummy_callback
,
&
dummy_fail_callback
,
&
dummy_callback
,
NULL
);
DBUG_PRINT
(
"info"
,
(
"file1: %d"
,
file1
.
file
));
if
(
my_chmod
(
file1_name
,
S_IRWXU
|
S_IRWXG
|
S_IRWXO
,
MYF
(
MY_WME
)))
if
(
my_chmod
(
file1_name
,
0777
,
MYF
(
MY_WME
)))
exit
(
1
);
my_pwrite
(
file1
.
file
,
(
const
uchar
*
)
"test file"
,
9
,
0
,
MYF
(
0
));
...
...
storage/maria/unittest/ma_pagecache_single.c
View file @
7e80c6e4
...
...
@@ -792,7 +792,7 @@ int main(int argc __attribute__((unused)),
my_delete
(
file2_name
,
MYF
(
0
));
DBUG_PRINT
(
"info"
,
(
"file1: %d"
,
file1
.
file
));
if
(
my_chmod
(
file1_name
,
S_IRWXU
|
S_IRWXG
|
S_IRWXO
,
MYF
(
MY_WME
)))
if
(
my_chmod
(
file1_name
,
0777
,
MYF
(
MY_WME
)))
exit
(
1
);
my_pwrite
(
file1
.
file
,
(
const
uchar
*
)
"test file"
,
9
,
0
,
MYF
(
MY_WME
));
...
...
storage/maria/unittest/ma_test_loghandler_pagecache-t.c
View file @
7e80c6e4
...
...
@@ -154,7 +154,7 @@ int main(int argc __attribute__((unused)), char *argv[])
}
pagecache_file_init
(
file1
,
&
dummy_callback
,
&
dummy_callback
,
&
dummy_fail_callback
,
maria_flush_log_for_page
,
NULL
);
if
(
my_chmod
(
file1_name
,
S_IRWXU
|
S_IRWXG
|
S_IRWXO
,
MYF
(
MY_WME
)))
if
(
my_chmod
(
file1_name
,
0777
,
MYF
(
MY_WME
)))
exit
(
1
);
{
...
...
storage/oqgraph/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -15,12 +15,11 @@ IF(BOOST_OK)
ADD_DEFINITIONS
(
-DHAVE_OQGRAPH
)
IF
(
MSVC
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
/EHsc"
)
E
NDIF
(
MSVC
)
IF
(
CMAKE_CXX_FLAGS
)
E
LSE
(
MSVC
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wno-deprecated"
)
STRING
(
REPLACE
"-fno-exceptions"
""
CMAKE_CXX_FLAGS
${
CMAKE_CXX_FLAGS
}
)
STRING
(
REPLACE
"-fno-implicit-templates"
""
CMAKE_CXX_FLAGS
${
CMAKE_CXX_FLAGS
}
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wno-deprecated"
)
ENDIF
()
ENDIF
(
MSVC
)
MYSQL_ADD_PLUGIN
(
oqgraph ha_oqgraph.cc graphcore.cc STORAGE_ENGINE
MODULE_ONLY
)
...
...
storage/pbxt/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -90,6 +90,5 @@ src/xt_config.h
src/xt_defs.h
src/xt_errno.h
)
SET
(
PBXT_PLUGIN_STATIC
"pbxt"
)
MYSQL_ADD_PLUGIN
(
pbxt
${
PBXT_SOURCES
}
STORAGE_ENGINE
)
MYSQL_ADD_PLUGIN
(
pbxt
${
PBXT_SOURCES
}
STORAGE_ENGINE STATIC_ONLY
)
storage/pbxt/src/datalog_xt.cc
View file @
7e80c6e4
...
...
@@ -26,8 +26,8 @@
#include <stdio.h>
#ifndef XT_WIN
#include <unistd.h>
#include <signal.h>
#endif
#include <signal.h>
#include <stdlib.h>
#ifndef DRIZZLED
...
...
storage/pbxt/src/pthread_xt.cc
View file @
7e80c6e4
...
...
@@ -45,22 +45,16 @@ xtPublic void xt_p_init_threading(void)
xtPublic
int
xt_p_set_normal_priority
(
pthread_t
thr
)
{
if
(
!
SetThreadPriority
(
thr
,
THREAD_PRIORITY_NORMAL
))
return
GetLastError
();
return
0
;
}
xtPublic
int
xt_p_set_low_priority
(
pthread_t
thr
)
{
if
(
!
SetThreadPriority
(
thr
,
THREAD_PRIORITY_LOWEST
))
return
GetLastError
();
return
0
;
}
xtPublic
int
xt_p_set_high_priority
(
pthread_t
thr
)
{
if
(
!
SetThreadPriority
(
thr
,
THREAD_PRIORITY_HIGHEST
))
return
GetLastError
();
return
0
;
}
...
...
@@ -401,31 +395,7 @@ xtPublic int xt_p_cond_timedwait(xt_cond_type *cond, xt_mutex_type *mt, struct t
xtPublic
int
xt_p_join
(
pthread_t
thread
,
void
**
value
)
{
DWORD
exitcode
;
while
(
1
)
{
switch
(
WaitForSingleObject
(
thread
,
10000
))
{
case
WAIT_OBJECT_0
:
return
0
;
case
WAIT_TIMEOUT
:
/* Don't do this! According to the Win docs:
* _endthread automatically closes the thread handle
* (whereas _endthreadex does not). Therefore, when using
* _beginthread and _endthread, do not explicitly close the
* thread handle by calling the Win32 CloseHandle API.
CloseHandle(thread);
*/
/* This is done so that if the thread was not [yet] in the running
* state when this function was called we won't deadlock here.
*/
if
(
GetExitCodeThread
(
thread
,
&
exitcode
)
&&
(
exitcode
==
STILL_ACTIVE
))
break
;
return
0
;
case
WAIT_FAILED
:
return
GetLastError
();
}
}
pthread_join
(
thread
,
value
);
return
0
;
}
...
...
storage/pbxt/src/thread_xt.cc
View file @
7e80c6e4
...
...
@@ -1513,16 +1513,7 @@ xtPublic pthread_t xt_run_thread(XTThreadPtr self, XTThreadPtr child, void *(*st
data
.
td_started
=
FALSE
;
data
.
td_thr
=
child
;
data
.
td_start_routine
=
start_routine
;
#ifdef XT_WIN
{
pthread_attr_t
attr
=
{
0
,
0
,
0
};
attr
.
priority
=
THREAD_PRIORITY_NORMAL
;
err
=
pthread_create
(
&
child_thread
,
&
attr
,
xt_thread_main
,
&
data
);
}
#else
err
=
pthread_create
(
&
child_thread
,
NULL
,
xt_thread_main
,
&
data
);
#endif
if
(
err
)
{
xt_free_thread
(
child
);
xt_throw_errno
(
XT_CONTEXT
,
err
);
...
...
storage/sphinx/ha_sphinx.cc
View file @
7e80c6e4
...
...
@@ -26,10 +26,10 @@
#include "field.h"
#include "item.h"
#include <mysqld_error.h>
#include <my_net.h>
#ifndef __WIN__
// UNIX-specific
#include <my_net.h>
#include <netdb.h>
#include <sys/un.h>
...
...
@@ -39,8 +39,6 @@
#else
// Windows-specific
#include <io.h>
#define strcasecmp stricmp
#define snprintf _snprintf
#define RECV_FLAGS 0
...
...
storage/xtradb/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -259,5 +259,5 @@ IF(WITH_INNODB)
SET
(
WITH_INNOBASE_STORAGE_ENGINE TRUE
)
ENDIF
()
MYSQL_ADD_PLUGIN
(
xtradb
${
INNOBASE_SOURCES
}
STORAGE_ENGINE
MYSQL_ADD_PLUGIN
(
xtradb
${
INNOBASE_SOURCES
}
STORAGE_ENGINE
DEFAULT
LINK_LIBRARIES
${
ZLIB_LIBRARY
}
)
storage/xtradb/log/log0recv.c
View file @
7e80c6e4
...
...
@@ -29,6 +29,13 @@ Created 9/20/1997 Heikki Tuuri
#include "log0recv.ic"
#endif
#include "config.h"
#ifdef HAVE_ALLOCA_H
#include "alloca.h"
#else
#include "malloc.h"
#endif
#include "mem0mem.h"
#include "buf0buf.h"
#include "buf0flu.h"
...
...
storage/xtradb/os/os0file.c
View file @
7e80c6e4
...
...
@@ -37,7 +37,7 @@ Created 10/21/1995 Heikki Tuuri
#ifdef UNIV_NONINL
#include "os0file.ic"
#endif
#include "ha_prototypes.h"
#include "ut0mem.h"
#include "srv0srv.h"
#include "srv0start.h"
...
...
@@ -1601,7 +1601,7 @@ os_file_create_func(
}
}
else
{
*
success
=
TRUE
;
if
(
os_aio
_use_native_aio
&&
((
attributes
&
FILE_FLAG_OVERLAPPED
)
!=
0
))
{
if
(
srv
_use_native_aio
&&
((
attributes
&
FILE_FLAG_OVERLAPPED
)
!=
0
))
{
ut_a
(
CreateIoCompletionPort
(
file
,
completion_port
,
0
,
0
));
}
}
...
...
@@ -4286,18 +4286,6 @@ os_aio_windows_handle(
ret
=
GetQueuedCompletionStatus
(
completion_port
,
&
len
,
&
key
,
(
OVERLAPPED
**
)
&
slot
,
INFINITE
);
if
(
srv_recovery_stats
&&
recv_recovery_is_on
()
&&
n_consecutive
)
{
mutex_enter
(
&
(
recv_sys
->
mutex
));
if
(
slot
->
type
==
OS_FILE_READ
)
{
recv_sys
->
stats_read_io_pages
+=
n_consecutive
;
recv_sys
->
stats_read_io_consecutive
[
n_consecutive
-
1
]
++
;
}
else
if
(
slot
->
type
==
OS_FILE_WRITE
)
{
recv_sys
->
stats_write_io_pages
+=
n_consecutive
;
recv_sys
->
stats_write_io_consecutive
[
n_consecutive
-
1
]
++
;
}
mutex_exit
(
&
(
recv_sys
->
mutex
));
}
/* If shutdown key was received, repost the shutdown message and exit */
if
(
ret
&&
(
key
==
IOCP_SHUTDOWN_KEY
))
{
PostQueuedCompletionStatus
(
completion_port
,
0
,
key
,
NULL
);
...
...
storage/xtradb/srv/srv0srv.c
View file @
7e80c6e4
...
...
@@ -136,20 +136,6 @@ UNIV_INTERN ulint srv_max_file_format_at_startup = DICT_TF_FORMAT_MAX;
/** Place locks to records only i.e. do not use next-key locking except
on duplicate key checking and foreign key checking */
UNIV_INTERN
ibool
srv_locks_unsafe_for_binlog
=
FALSE
;
#ifdef __WIN__
/* Windows native condition variables. We use runtime loading / function
pointers, because they are not available on Windows Server 2003 and
Windows XP/2000.
We use condition for events on Windows if possible, even if os_event
resembles Windows kernel event object well API-wise. The reason is
performance, kernel objects are heavyweights and WaitForSingleObject() is a
performance killer causing calling thread to context switch. Besides, Innodb
is preallocating large number (often millions) of os_events. With kernel event
objects it takes a big chunk out of non-paged pool, which is better suited
for tasks like IO than for storing idle event objects. */
UNIV_INTERN
ibool
srv_use_native_conditions
=
FALSE
;
#endif
/* __WIN__ */
/* If this flag is TRUE, then we will use the native aio of the
OS (provided we compiled Innobase with it in), otherwise we will
...
...
storage/xtradb/srv/srv0start.c
View file @
7e80c6e4
...
...
@@ -1377,7 +1377,7 @@ innobase_start_or_create_for_mysql(void)
}
else
if
(
0
==
ut_strcmp
(
srv_file_flush_method_str
,
"async_unbuffered"
))
{
srv_win_file_flush_method
=
SRV_WIN_IO_UNBUFFERED
;
os_aio
_use_native_aio
=
TRUE
;
srv
_use_native_aio
=
TRUE
;
#endif
}
else
{
ut_print_timestamp
(
stderr
);
...
...
unittest/mytap/CMakeLists.txt
View file @
7e80c6e4
...
...
@@ -15,5 +15,3 @@
INCLUDE_DIRECTORIES
(
${
CMAKE_SOURCE_DIR
}
/include
)
ADD_LIBRARY
(
mytap tap.c
)
MY_ADD_TESTS
(
t/basic
)
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