summaryrefslogtreecommitdiff
path: root/plugin
diff options
context:
space:
mode:
Diffstat (limited to 'plugin')
-rw-r--r--plugin/auth_gssapi/client_plugin.cc5
-rw-r--r--plugin/auth_gssapi/gssapi_client.cc3
-rw-r--r--plugin/auth_gssapi/gssapi_errmsg.cc2
-rw-r--r--plugin/auth_gssapi/gssapi_server.cc3
-rw-r--r--plugin/auth_gssapi/server_plugin.cc1
-rw-r--r--plugin/auth_gssapi/sspi_client.cc5
-rw-r--r--plugin/auth_gssapi/sspi_errmsg.cc3
-rw-r--r--plugin/auth_gssapi/sspi_server.cc1
-rw-r--r--plugin/cracklib_password_check/cracklib_password_check.c2
-rw-r--r--plugin/feedback/feedback.h1
-rw-r--r--plugin/file_key_management/parser.cc1
-rw-r--r--plugin/handler_socket/handlersocket/database.cpp5
-rw-r--r--plugin/handler_socket/handlersocket/handlersocket.cpp3
-rw-r--r--plugin/handler_socket/handlersocket/hstcpsvr.cpp6
-rw-r--r--plugin/handler_socket/handlersocket/hstcpsvr_worker.cpp4
-rw-r--r--plugin/handler_socket/handlersocket/mysql_incl.hpp3
-rw-r--r--plugin/handler_socket/libhsclient/auto_addrinfo.hpp3
-rw-r--r--plugin/handler_socket/libhsclient/hstcpcli.cpp3
-rw-r--r--plugin/handler_socket/libhsclient/socket.cpp5
-rw-r--r--plugin/locale_info/locale_info.cc1
-rw-r--r--plugin/metadata_lock_info/metadata_lock_info.cc2
-rw-r--r--plugin/query_response_time/plugin.cc1
-rw-r--r--plugin/semisync/semisync.cc1
-rw-r--r--plugin/semisync/semisync_master.cc1
-rw-r--r--plugin/semisync/semisync_master_plugin.cc1
-rw-r--r--plugin/semisync/semisync_slave.cc1
-rw-r--r--plugin/semisync/semisync_slave_plugin.cc1
-rw-r--r--plugin/server_audit/server_audit.c8
-rw-r--r--plugin/server_audit/test_audit_v4.c1
-rw-r--r--plugin/simple_password_check/simple_password_check.c1
-rw-r--r--plugin/user_variables/user_variables.cc1
-rw-r--r--plugin/userstat/userstat.cc2
-rw-r--r--plugin/wsrep_info/plugin.cc2
33 files changed, 39 insertions, 44 deletions
diff --git a/plugin/auth_gssapi/client_plugin.cc b/plugin/auth_gssapi/client_plugin.cc
index 0ab619a08e6..032300b5537 100644
--- a/plugin/auth_gssapi/client_plugin.cc
+++ b/plugin/auth_gssapi/client_plugin.cc
@@ -31,13 +31,12 @@ POSSIBILITY OF SUCH DAMAGE.
GSSAPI authentication plugin, client side
*/
-#include <string.h>
-#include <stdarg.h>
+#include <my_global.h>
#include <mysqld_error.h>
#include <mysql/client_plugin.h>
#include <mysql.h>
-#include <stdio.h>
#include "common.h"
+#include <string.h>
extern int auth_client(char *principal_name,
char *mech,
diff --git a/plugin/auth_gssapi/gssapi_client.cc b/plugin/auth_gssapi/gssapi_client.cc
index a05ea158e4d..05ce62a31a3 100644
--- a/plugin/auth_gssapi/gssapi_client.cc
+++ b/plugin/auth_gssapi/gssapi_client.cc
@@ -26,9 +26,8 @@ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
+#include <my_global.h>
#include <gssapi/gssapi.h>
-#include <string.h>
-#include <stdio.h>
#include <mysql/plugin_auth.h>
#include <mysqld_error.h>
#include <mysql.h>
diff --git a/plugin/auth_gssapi/gssapi_errmsg.cc b/plugin/auth_gssapi/gssapi_errmsg.cc
index 8ea4cab5b02..f92a03983ba 100644
--- a/plugin/auth_gssapi/gssapi_errmsg.cc
+++ b/plugin/auth_gssapi/gssapi_errmsg.cc
@@ -26,8 +26,10 @@ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
+#include <my_global.h>
#include <gssapi.h>
#include <string.h>
+
void gssapi_errmsg(OM_uint32 major, OM_uint32 minor, char *buf, size_t size)
{
OM_uint32 message_context;
diff --git a/plugin/auth_gssapi/gssapi_server.cc b/plugin/auth_gssapi/gssapi_server.cc
index 50c34ecc573..269e5691da9 100644
--- a/plugin/auth_gssapi/gssapi_server.cc
+++ b/plugin/auth_gssapi/gssapi_server.cc
@@ -1,6 +1,5 @@
-#include <my_config.h>
+#include <my_global.h>
#include <gssapi/gssapi.h>
-#include <stdio.h>
#include <mysql/plugin_auth.h>
#include <my_sys.h>
#include <mysqld_error.h>
diff --git a/plugin/auth_gssapi/server_plugin.cc b/plugin/auth_gssapi/server_plugin.cc
index 0c0bcbbbb72..5d6a92fe5ca 100644
--- a/plugin/auth_gssapi/server_plugin.cc
+++ b/plugin/auth_gssapi/server_plugin.cc
@@ -31,6 +31,7 @@
GSSAPI authentication plugin, server side
*/
+#include <my_global.h>
#include <my_sys.h>
#include <mysqld_error.h>
#include <mysql/plugin_auth.h>
diff --git a/plugin/auth_gssapi/sspi_client.cc b/plugin/auth_gssapi/sspi_client.cc
index 34c1ce2e7ee..c9fb9d62fe5 100644
--- a/plugin/auth_gssapi/sspi_client.cc
+++ b/plugin/auth_gssapi/sspi_client.cc
@@ -27,11 +27,10 @@ POSSIBILITY OF SUCH DAMAGE.
*/
#define SECURITY_WIN32
+#include <my_global.h>
#include <windows.h>
#include <sspi.h>
#include <SecExt.h>
-#include <stdarg.h>
-#include <stdio.h>
#include <mysql/plugin_auth.h>
#include <mysql.h>
@@ -180,4 +179,4 @@ cleanup:
FreeCredentialsHandle(&cred);
free(out);
return ret;
-} \ No newline at end of file
+}
diff --git a/plugin/auth_gssapi/sspi_errmsg.cc b/plugin/auth_gssapi/sspi_errmsg.cc
index 961ef51f42e..48adad72677 100644
--- a/plugin/auth_gssapi/sspi_errmsg.cc
+++ b/plugin/auth_gssapi/sspi_errmsg.cc
@@ -26,8 +26,9 @@ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
+#include <my_global.h>
#include <windows.h>
-#include <stdio.h>
+#include <string.h>
#define ERRSYM(x) {x, #x}
static struct {
diff --git a/plugin/auth_gssapi/sspi_server.cc b/plugin/auth_gssapi/sspi_server.cc
index d2c2ae7e4b9..866e9d55c26 100644
--- a/plugin/auth_gssapi/sspi_server.cc
+++ b/plugin/auth_gssapi/sspi_server.cc
@@ -26,6 +26,7 @@ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
+#include <my_global.h>
#include "sspi.h"
#include "common.h"
#include "server_plugin.h"
diff --git a/plugin/cracklib_password_check/cracklib_password_check.c b/plugin/cracklib_password_check/cracklib_password_check.c
index 94587a6d659..d4c3aba5b77 100644
--- a/plugin/cracklib_password_check/cracklib_password_check.c
+++ b/plugin/cracklib_password_check/cracklib_password_check.c
@@ -13,7 +13,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
-#include <my_config.h>
+#include <my_global.h>
#include <mysql/plugin_password_validation.h>
#include <crack.h>
#include <string.h>
diff --git a/plugin/feedback/feedback.h b/plugin/feedback/feedback.h
index 5e7e7b1516e..43c9f4ee844 100644
--- a/plugin/feedback/feedback.h
+++ b/plugin/feedback/feedback.h
@@ -14,6 +14,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA */
#define MYSQL_SERVER 1
+#include <my_global.h>
#include <sql_class.h>
namespace feedback {
diff --git a/plugin/file_key_management/parser.cc b/plugin/file_key_management/parser.cc
index ac78186a488..03f78422c47 100644
--- a/plugin/file_key_management/parser.cc
+++ b/plugin/file_key_management/parser.cc
@@ -69,6 +69,7 @@ Example:
openssl enc -aes-256-cbc -md sha1 -k "secret" -in keys.txt -out keys.enc
***********************************************************************/
+#include <my_global.h>
#include "parser.h"
#include <m_string.h>
#include <mysys_err.h>
diff --git a/plugin/handler_socket/handlersocket/database.cpp b/plugin/handler_socket/handlersocket/database.cpp
index 2ddff7689ad..0761c1bc09d 100644
--- a/plugin/handler_socket/handlersocket/database.cpp
+++ b/plugin/handler_socket/handlersocket/database.cpp
@@ -6,10 +6,7 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
-
-#include <stdlib.h>
-#include <stdio.h>
+#include <my_global.h>
#include <string.h>
#include "database.hpp"
diff --git a/plugin/handler_socket/handlersocket/handlersocket.cpp b/plugin/handler_socket/handlersocket/handlersocket.cpp
index 6e4c03fcc24..8133497044c 100644
--- a/plugin/handler_socket/handlersocket/handlersocket.cpp
+++ b/plugin/handler_socket/handlersocket/handlersocket.cpp
@@ -6,8 +6,7 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
-
+#include <my_global.h>
#include <memory>
#include <string>
#include <stdio.h>
diff --git a/plugin/handler_socket/handlersocket/hstcpsvr.cpp b/plugin/handler_socket/handlersocket/hstcpsvr.cpp
index 925020023bc..250ef2c7be5 100644
--- a/plugin/handler_socket/handlersocket/hstcpsvr.cpp
+++ b/plugin/handler_socket/handlersocket/hstcpsvr.cpp
@@ -6,15 +6,11 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
-
-#include <stdlib.h>
+#include <my_global.h>
#include <vector>
-#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <unistd.h>
-#include <fcntl.h>
#include <sys/resource.h>
#include "hstcpsvr.hpp"
diff --git a/plugin/handler_socket/handlersocket/hstcpsvr_worker.cpp b/plugin/handler_socket/handlersocket/hstcpsvr_worker.cpp
index c254d17dff5..9863602af7a 100644
--- a/plugin/handler_socket/handlersocket/hstcpsvr_worker.cpp
+++ b/plugin/handler_socket/handlersocket/hstcpsvr_worker.cpp
@@ -6,13 +6,11 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
-#include <sys/types.h>
+#include <my_global.h>
#include <netinet/in.h>
#include <errno.h>
#include <poll.h>
#include <unistd.h>
-#include <fcntl.h>
#include <stdexcept>
#include <signal.h>
#include <list>
diff --git a/plugin/handler_socket/handlersocket/mysql_incl.hpp b/plugin/handler_socket/handlersocket/mysql_incl.hpp
index 0fb4fceb143..0d056a7ed4a 100644
--- a/plugin/handler_socket/handlersocket/mysql_incl.hpp
+++ b/plugin/handler_socket/handlersocket/mysql_incl.hpp
@@ -19,8 +19,7 @@
#define MYSQL_SERVER 1
-#include <my_config.h>
-
+#include <my_global.h>
#include <mysql_version.h>
#if MYSQL_VERSION_ID >= 50505
diff --git a/plugin/handler_socket/libhsclient/auto_addrinfo.hpp b/plugin/handler_socket/libhsclient/auto_addrinfo.hpp
index aee22a1d0f6..f9db70fe971 100644
--- a/plugin/handler_socket/libhsclient/auto_addrinfo.hpp
+++ b/plugin/handler_socket/libhsclient/auto_addrinfo.hpp
@@ -9,8 +9,7 @@
#ifndef DENA_AUTO_ADDRINFO_HPP
#define DENA_AUTO_ADDRINFO_HPP
-#include <my_config.h>
-#include <sys/types.h>
+#include <my_global.h>
#include <sys/socket.h>
#include <netdb.h>
#include <string.h>
diff --git a/plugin/handler_socket/libhsclient/hstcpcli.cpp b/plugin/handler_socket/libhsclient/hstcpcli.cpp
index 21c964cb046..461bed3f5d0 100644
--- a/plugin/handler_socket/libhsclient/hstcpcli.cpp
+++ b/plugin/handler_socket/libhsclient/hstcpcli.cpp
@@ -6,8 +6,7 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
-
+#include <my_global.h>
#include <stdexcept>
#include "hstcpcli.hpp"
diff --git a/plugin/handler_socket/libhsclient/socket.cpp b/plugin/handler_socket/libhsclient/socket.cpp
index 2c93a3b4846..f1cdc9fb20f 100644
--- a/plugin/handler_socket/libhsclient/socket.cpp
+++ b/plugin/handler_socket/libhsclient/socket.cpp
@@ -6,13 +6,10 @@
* See COPYRIGHT.txt for details.
*/
-#include <my_config.h>
+#include <my_global.h>
#include <stdexcept>
#include <string.h>
-#include <errno.h>
-#include <unistd.h>
-#include <fcntl.h>
#include <signal.h>
#include <sys/un.h>
diff --git a/plugin/locale_info/locale_info.cc b/plugin/locale_info/locale_info.cc
index 3d775c0be7c..e444b4fade0 100644
--- a/plugin/locale_info/locale_info.cc
+++ b/plugin/locale_info/locale_info.cc
@@ -26,6 +26,7 @@
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+#include <my_global.h>
#include <sql_class.h> // THD
#include <table.h> // ST_SCHEMA_TABLE
#include <mysql/plugin.h>
diff --git a/plugin/metadata_lock_info/metadata_lock_info.cc b/plugin/metadata_lock_info/metadata_lock_info.cc
index f2cdb99b82b..9fe764ea30b 100644
--- a/plugin/metadata_lock_info/metadata_lock_info.cc
+++ b/plugin/metadata_lock_info/metadata_lock_info.cc
@@ -14,7 +14,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA */
#define MYSQL_SERVER 1
-#include "my_config.h"
+#include <my_global.h>
#include "mysql_version.h"
#include "mysql/plugin.h"
#include "sql_class.h"
diff --git a/plugin/query_response_time/plugin.cc b/plugin/query_response_time/plugin.cc
index 0ed8b88dc60..7c4a7076c59 100644
--- a/plugin/query_response_time/plugin.cc
+++ b/plugin/query_response_time/plugin.cc
@@ -14,6 +14,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA */
#define MYSQL_SERVER
+#include <my_global.h>
#include <sql_class.h>
#include <table.h>
#include <sql_show.h>
diff --git a/plugin/semisync/semisync.cc b/plugin/semisync/semisync.cc
index 4a80360ba4d..df37f03ec2f 100644
--- a/plugin/semisync/semisync.cc
+++ b/plugin/semisync/semisync.cc
@@ -16,6 +16,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include "semisync.h"
const unsigned char ReplSemiSyncBase::kPacketMagicNum = 0xef;
diff --git a/plugin/semisync/semisync_master.cc b/plugin/semisync/semisync_master.cc
index 7901853c3f8..092ab38f6bf 100644
--- a/plugin/semisync/semisync_master.cc
+++ b/plugin/semisync/semisync_master.cc
@@ -16,6 +16,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include "semisync_master.h"
#define TIME_THOUSAND 1000
diff --git a/plugin/semisync/semisync_master_plugin.cc b/plugin/semisync/semisync_master_plugin.cc
index 309910312c4..b46cf5d79cb 100644
--- a/plugin/semisync/semisync_master_plugin.cc
+++ b/plugin/semisync/semisync_master_plugin.cc
@@ -16,6 +16,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include "semisync_master.h"
#include "sql_class.h" // THD
diff --git a/plugin/semisync/semisync_slave.cc b/plugin/semisync/semisync_slave.cc
index 5f98472d5d7..ff8a40aafac 100644
--- a/plugin/semisync/semisync_slave.cc
+++ b/plugin/semisync/semisync_slave.cc
@@ -15,6 +15,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include "semisync_slave.h"
char rpl_semi_sync_slave_enabled;
diff --git a/plugin/semisync/semisync_slave_plugin.cc b/plugin/semisync/semisync_slave_plugin.cc
index 3a6c7625d93..df9e8e10429 100644
--- a/plugin/semisync/semisync_slave_plugin.cc
+++ b/plugin/semisync/semisync_slave_plugin.cc
@@ -16,6 +16,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include "semisync_slave.h"
#include <mysql.h>
diff --git a/plugin/server_audit/server_audit.c b/plugin/server_audit/server_audit.c
index 65de695ac9e..af6d2d95a42 100644
--- a/plugin/server_audit/server_audit.c
+++ b/plugin/server_audit/server_audit.c
@@ -20,10 +20,6 @@
#define _my_thread_var loc_thread_var
#include <my_config.h>
-#include <stdio.h>
-#include <time.h>
-#include <string.h>
-#include <fcntl.h>
#ifndef _WIN32
#include <syslog.h>
@@ -75,6 +71,7 @@ static void closelog() {}
*/
#if !defined(MYSQL_DYNAMIC_PLUGIN) && !defined(MARIADB_ONLY)
+#include <typelib.h>
#define MARIADB_ONLY
#endif /*MYSQL_PLUGIN_DYNAMIC*/
@@ -82,11 +79,12 @@ static void closelog() {}
#define MYSQL_SERVICE_LOGGER_INCLUDED
#endif /*MARIADB_ONLY*/
+#include <my_global.h>
#include <my_base.h>
-//#include <my_dir.h>
#include <typelib.h>
#include <mysql/plugin.h>
#include <mysql/plugin_audit.h>
+#include <string.h>
#ifndef RTLD_DEFAULT
#define RTLD_DEFAULT NULL
#endif
diff --git a/plugin/server_audit/test_audit_v4.c b/plugin/server_audit/test_audit_v4.c
index ae7527f8449..65571b14c11 100644
--- a/plugin/server_audit/test_audit_v4.c
+++ b/plugin/server_audit/test_audit_v4.c
@@ -1,5 +1,6 @@
#define PLUGIN_CONTEXT
+/* Can't use <my_global.h> as this includes plugin.h */
#include <stdio.h>
typedef void *MYSQL_THD;
diff --git a/plugin/simple_password_check/simple_password_check.c b/plugin/simple_password_check/simple_password_check.c
index f1cd5aaf17f..60d8a9ea815 100644
--- a/plugin/simple_password_check/simple_password_check.c
+++ b/plugin/simple_password_check/simple_password_check.c
@@ -14,6 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
+#include <my_global.h>
#include <my_sys.h>
#include <mysqld_error.h>
#include <mysql/plugin_password_validation.h>
diff --git a/plugin/user_variables/user_variables.cc b/plugin/user_variables/user_variables.cc
index 9190b2effb7..227455e5696 100644
--- a/plugin/user_variables/user_variables.cc
+++ b/plugin/user_variables/user_variables.cc
@@ -14,6 +14,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#define MYSQL_SERVER
+#include <my_global.h>
#include <sql_class.h>
#include <table.h>
#include <sql_show.h>
diff --git a/plugin/userstat/userstat.cc b/plugin/userstat/userstat.cc
index 96d926ac908..2084453fbca 100644
--- a/plugin/userstat/userstat.cc
+++ b/plugin/userstat/userstat.cc
@@ -1,4 +1,4 @@
-#include <my_config.h>
+#include <my_global.h>
#include <mysql/plugin.h>
#include <mysql_version.h>
#include "table.h"
diff --git a/plugin/wsrep_info/plugin.cc b/plugin/wsrep_info/plugin.cc
index ed502d30f88..428bcc5dcfc 100644
--- a/plugin/wsrep_info/plugin.cc
+++ b/plugin/wsrep_info/plugin.cc
@@ -17,7 +17,7 @@
#define MYSQL_SERVER
#endif
-#include <my_config.h>
+#include <my_global.h>
#include <mysql/plugin.h>
#include <table.h> /* ST_SCHEMA_TABLE */
#include <sql_show.h>