diff --git a/plugins/cio/cio_npipe.c b/plugins/cio/cio_npipe.c index 1a644290..cb4de1a8 100644 --- a/plugins/cio/cio_npipe.c +++ b/plugins/cio/cio_npipe.c @@ -82,9 +82,7 @@ MARIADB_CIO_PLUGIN _mysql_client_plugin_declaration_ = "LGPL", NULL, NULL, - &cio_npipe_methods, - NULL, - NULL + &cio_npipe_methods }; struct st_cio_npipe { diff --git a/plugins/cio/cio_shmem.c b/plugins/cio/cio_shmem.c index 6c02ede0..d632713f 100644 --- a/plugins/cio/cio_shmem.c +++ b/plugins/cio/cio_shmem.c @@ -84,8 +84,7 @@ MARIADB_CIO_PLUGIN _mysql_client_plugin_declaration_= NULL, NULL, &cio_shm_methods, - NULL, - NULL + }; enum enum_shm_events diff --git a/plugins/connection/replication.c b/plugins/connection/replication.c index 2caaec84..7a21bf1e 100644 --- a/plugins/connection/replication.c +++ b/plugins/connection/replication.c @@ -29,7 +29,10 @@ #include #include #include + +#ifndef WIN32 #include +#endif /* function prototypes */ MYSQL *repl_connect(MYSQL *mysql, const char *host, const char *user, const char *passwd, @@ -129,10 +132,14 @@ my_bool repl_parse_url(const char *url, REPL_DATA *data) data->host[MARIADB_SLAVE]= slaves[0]; else { - struct timeval tp; int random_nr; +#ifndef WIN32 + struct timeval tp; gettimeofday(&tp,NULL); srand(tp.tv_usec / 1000 + tp.tv_sec * 1000); +#else + srand(GetTickCount()); +#endif random_nr= rand() % num_slaves; data->host[MARIADB_SLAVE]= slaves[random_nr]; diff --git a/plugins/trace/trace_example.c b/plugins/trace/trace_example.c index 0dd85d44..a8fc75ef 100644 --- a/plugins/trace/trace_example.c +++ b/plugins/trace/trace_example.c @@ -47,7 +47,7 @@ void trace_callback(int mode, MYSQL *mysql, const uchar *buffer, size_t length); #ifndef HAVE_TRACE_EXAMPLE_PLUGIN_DYNAMIC struct st_mysql_client_plugin trace_example_plugin= #else -struct st_mysql_client_plugin _mysql_client_plugin_declare_= +struct st_mysql_client_plugin _mysql_client_plugin_declaration_ = #endif { MARIADB_CLIENT_TRACE_PLUGIN,