summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/heap.h3
-rw-r--r--include/m_ctype.h3
-rw-r--r--include/m_string.h12
-rw-r--r--include/maria.h2
-rw-r--r--include/my_alarm.h3
-rw-r--r--include/my_bitmap.h2
-rw-r--r--include/my_dbug.h4
-rw-r--r--include/my_decimal_limits.h2
-rw-r--r--include/my_getopt.h2
-rw-r--r--include/my_global.h33
-rw-r--r--include/my_stacktrace.h3
-rw-r--r--include/my_time.h3
-rw-r--r--include/myisam.h2
-rw-r--r--include/mysql.h3
-rw-r--r--include/mysql.h.pp1
-rw-r--r--include/mysql/client_plugin.h7
-rw-r--r--include/mysql/plugin.h40
-rw-r--r--include/mysql_com.h1
-rw-r--r--include/mysql_embed.h3
-rw-r--r--include/mysys_err.h3
-rw-r--r--include/sslopt-longopts.h3
-rw-r--r--include/welcome_copyright_notice.h8
22 files changed, 78 insertions, 65 deletions
diff --git a/include/heap.h b/include/heap.h
index 6ce95c88521..10b165d89c6 100644
--- a/include/heap.h
+++ b/include/heap.h
@@ -1,5 +1,4 @@
-/*
- Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+/* Copyright (c) 2000, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/m_ctype.h b/include/m_ctype.h
index 2a7175f739a..00f02edc620 100644
--- a/include/m_ctype.h
+++ b/include/m_ctype.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2010, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/m_string.h b/include/m_string.h
index 6268888028f..7c95c7319dc 100644
--- a/include/m_string.h
+++ b/include/m_string.h
@@ -1,5 +1,5 @@
/*
- Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+ Copyright (c) 2000, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -58,14 +58,16 @@
/* Unixware 7 */
#if !defined(HAVE_BFILL)
# define bfill(A,B,C) memset((A),(C),(B))
-# define bmove_align(A,B,C) memcpy((A),(B),(C))
#endif
+# define bmove_align(A,B,C) memcpy((A),(B),(C))
+
#if !defined(HAVE_BCMP)
-# define bcopy(s, d, n) memcpy((d), (s), (n))
# define bcmp(A,B,C) memcmp((A),(B),(C))
-# define bzero(A,B) memset((A),0,(B))
-# define bmove_align(A,B,C) memcpy((A),(B),(C))
+#endif
+
+#if !defined(bzero) && (!defined(HAVE_BZERO) || !defined(HAVE_DECL_BZERO))
+# define bzero(A,B) memset((A),0,(B))
#endif
#if defined(__cplusplus)
diff --git a/include/maria.h b/include/maria.h
index 3ee5b6b9df8..404ce98dafd 100644
--- a/include/maria.h
+++ b/include/maria.h
@@ -336,6 +336,8 @@ extern void maria_enable_logging(MARIA_HA *info);
#define HA_RECOVER_FORCE 4 /* Recover even if we loose rows */
#define HA_RECOVER_QUICK 8 /* Don't check rows in data file */
+#define HA_RECOVER_ANY (HA_RECOVER_DEFAULT | HA_RECOVER_BACKUP | HA_RECOVER_FORCE | HA_RECOVER_QUICK)
+
/* this is used to pass to mysql_mariachk_table */
#define MARIA_CHK_REPAIR 1 /* equivalent to mariachk -r */
diff --git a/include/my_alarm.h b/include/my_alarm.h
index 57d86f56755..c3707cba395 100644
--- a/include/my_alarm.h
+++ b/include/my_alarm.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2010, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/my_bitmap.h b/include/my_bitmap.h
index 7b78252ea27..a6cd874255a 100644
--- a/include/my_bitmap.h
+++ b/include/my_bitmap.h
@@ -1,4 +1,4 @@
-/* Copyright (c) 2000, 2011, Oracle and/or its affiliates.
+/* Copyright (c) 2001, 2011, Oracle and/or its affiliates.
Copyright (c) 2009-2011, Monty Program Ab
This program is free software; you can redistribute it and/or modify
diff --git a/include/my_dbug.h b/include/my_dbug.h
index fb5838e8b5c..88bbc3f968f 100644
--- a/include/my_dbug.h
+++ b/include/my_dbug.h
@@ -1,5 +1,5 @@
-/* Copyright (c) 2000, 2010, Oracle and/or its affiliates.
- Copyright (c) 2009-2011 Monty Program Ab
+/* Copyright (c) 2000, 2010, Oracle and/or its affiliates.
+ Copyright (C) 2000-2011 Monty Program Ab
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/my_decimal_limits.h b/include/my_decimal_limits.h
index b395a2ed144..50d70357c42 100644
--- a/include/my_decimal_limits.h
+++ b/include/my_decimal_limits.h
@@ -38,7 +38,7 @@
/**
maximum length of string representation (number of maximum decimal
- digits + 1 position for sign + 1 position for decimal point)
+ digits + 1 position for sign + 1 position for decimal point, no terminator)
*/
#define DECIMAL_MAX_STR_LENGTH (DECIMAL_MAX_POSSIBLE_PRECISION + 2)
diff --git a/include/my_getopt.h b/include/my_getopt.h
index 092accc05a1..61c4b054615 100644
--- a/include/my_getopt.h
+++ b/include/my_getopt.h
@@ -1,5 +1,5 @@
/*
- Copyright (c) 2002, 2011, Oracle and/or its affiliates. All rights reserved.
+ Copyright (c) 2002, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/my_global.h b/include/my_global.h
index 451cb9127a3..8d54448f477 100644
--- a/include/my_global.h
+++ b/include/my_global.h
@@ -1,5 +1,5 @@
/*
- Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
+ Copyright (c) 2001, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -45,6 +45,8 @@
#undef __WIN__
#undef __WIN32__
#define HAVE_ERRNO_AS_DEFINE
+#define _POSIX_MONOTONIC_CLOCK
+#define _POSIX_THREAD_CPUTIME
#endif /* __CYGWIN__ */
/* to make command line shorter we'll define USE_PRAGMA_INTERFACE here */
@@ -1386,21 +1388,10 @@ do { doubleget_union _tmp; \
#define NO_EMBEDDED_ACCESS_CHECKS
#endif
-#if defined(_WIN32)
+#ifdef _WIN32
#define dlsym(lib, name) (void*)GetProcAddress((HMODULE)lib, name)
#define dlopen(libname, unused) LoadLibraryEx(libname, NULL, 0)
#define dlclose(lib) FreeLibrary((HMODULE)lib)
-#ifndef HAVE_DLOPEN
-#define HAVE_DLOPEN
-#endif
-#endif
-
-#if defined(HAVE_DLFCN_H)
-#include <dlfcn.h>
-#endif
-
-#ifndef HAVE_DLERROR
-#ifdef _WIN32
static inline char *dlerror(void)
{
static char win_errormsg[2048];
@@ -1409,9 +1400,23 @@ static inline char *dlerror(void)
return win_errormsg;
return "";
}
+#define HAVE_DLOPEN 1
+#define HAVE_DLERROR 1
+#endif
+
+#ifdef HAVE_DLFCN_H
+#include <dlfcn.h>
+#endif
+
+#ifdef HAVE_DLOPEN
+#ifndef HAVE_DLERROR
+#define dlerror() ""
+#endif
#else
#define dlerror() "No support for dynamic loading (static build?)"
-#endif
+#define dlopen(A,B) 0
+#define dlsym(A,B) 0
+#define dlclose(A) 0
#endif
/*
diff --git a/include/my_stacktrace.h b/include/my_stacktrace.h
index a9590a76368..41440fb2c74 100644
--- a/include/my_stacktrace.h
+++ b/include/my_stacktrace.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2001, 2010, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/my_time.h b/include/my_time.h
index 668b57fc052..9bd545bb850 100644
--- a/include/my_time.h
+++ b/include/my_time.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2004, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/myisam.h b/include/myisam.h
index 0aa8fe79c27..3d4eecb7cbe 100644
--- a/include/myisam.h
+++ b/include/myisam.h
@@ -1,5 +1,5 @@
/*
- Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+ Copyright (c) 2000, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/mysql.h b/include/mysql.h
index d06db7ed25d..fb99242132b 100644
--- a/include/mysql.h
+++ b/include/mysql.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/mysql.h.pp b/include/mysql.h.pp
index 556ba91c7b9..9592ec7b046 100644
--- a/include/mysql.h.pp
+++ b/include/mysql.h.pp
@@ -140,6 +140,7 @@ void get_salt_from_password(unsigned char *res, const char *password);
void make_password_from_salt(char *to, const unsigned char *hash_stage2);
char *octet2hex(char *to, const char *str, unsigned int len);
char *get_tty_password(const char *opt_message);
+void get_tty_password_buff(const char *opt_message, char *to, size_t length);
const char *mysql_errno_to_sqlstate(unsigned int mysql_errno);
my_bool my_thread_init(void);
void my_thread_end(void);
diff --git a/include/mysql/client_plugin.h b/include/mysql/client_plugin.h
index 35b415fdaf0..b2df0019dfe 100644
--- a/include/mysql/client_plugin.h
+++ b/include/mysql/client_plugin.h
@@ -30,22 +30,19 @@
unlike other compilers, uses C++ mangling for variables not only
for functions.
*/
+#undef MYSQL_PLUGIN_EXPORT
#if defined(_MSC_VER)
-#if defined(MYSQL_DYNAMIC_PLUGIN)
#ifdef __cplusplus
#define MYSQL_PLUGIN_EXPORT extern "C" __declspec(dllexport)
#else
#define MYSQL_PLUGIN_EXPORT __declspec(dllexport)
#endif
-#else /* MYSQL_DYNAMIC_PLUGIN */
+#else /*_MSC_VER */
#ifdef __cplusplus
#define MYSQL_PLUGIN_EXPORT extern "C"
#else
#define MYSQL_PLUGIN_EXPORT
#endif
-#endif /*MYSQL_DYNAMIC_PLUGIN */
-#else /*_MSC_VER */
-#define MYSQL_PLUGIN_EXPORT
#endif
#ifndef MYSQL_ABI_CHECK
diff --git a/include/mysql/plugin.h b/include/mysql/plugin.h
index 4f70fe45d43..32c971bb99e 100644
--- a/include/mysql/plugin.h
+++ b/include/mysql/plugin.h
@@ -1,4 +1,4 @@
-/* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
+/* Copyright (c) 2005, 2010, Oracle and/or its affiliates
Copyright (C) 2009-2011 Monty Program Ab
This program is free software; you can redistribute it and/or modify
@@ -24,21 +24,17 @@
for functions.
*/
#if defined(_MSC_VER)
-#if defined(MYSQL_DYNAMIC_PLUGIN)
#ifdef __cplusplus
#define MYSQL_PLUGIN_EXPORT extern "C" __declspec(dllexport)
#else
#define MYSQL_PLUGIN_EXPORT __declspec(dllexport)
#endif
-#else /* MYSQL_DYNAMIC_PLUGIN */
+#else /*_MSC_VER */
#ifdef __cplusplus
- #define MYSQL_PLUGIN_EXPORT extern "C"
+ #define MYSQL_PLUGIN_EXPORT extern "C"
#else
- #define MYSQL_PLUGIN_EXPORT
+ #define MYSQL_PLUGIN_EXPORT
#endif
-#endif /*MYSQL_DYNAMIC_PLUGIN */
-#else /*_MSC_VER */
-#define MYSQL_PLUGIN_EXPORT
#endif
#ifdef __cplusplus
@@ -122,20 +118,26 @@ int PSIZE= sizeof(struct st_mysql_plugin); \
struct st_mysql_plugin DECLS[]= {
#define MARIA_DECLARE_PLUGIN__(NAME, VERSION, PSIZE, 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[]= {
+int VERSION= MARIA_PLUGIN_INTERFACE_VERSION; \
+int PSIZE= sizeof(struct st_maria_plugin); \
+struct st_maria_plugin DECLS[]= {
#else
#define __MYSQL_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS) \
-MYSQL_PLUGIN_EXPORT int _mysql_plugin_interface_version_= MYSQL_PLUGIN_INTERFACE_VERSION; \
-MYSQL_PLUGIN_EXPORT int _mysql_sizeof_struct_st_plugin_= sizeof(struct st_mysql_plugin); \
-MYSQL_PLUGIN_EXPORT struct st_mysql_plugin _mysql_plugin_declarations_[]= {
-
-#define MARIA_DECLARE_PLUGIN__(NAME, VERSION, PSIZE, DECLS) \
-MYSQL_PLUGIN_EXPORT int _maria_plugin_interface_version_= MARIA_PLUGIN_INTERFACE_VERSION; \
-MYSQL_PLUGIN_EXPORT int _maria_sizeof_struct_st_plugin_= sizeof(struct st_maria_plugin); \
-MYSQL_PLUGIN_EXPORT struct st_maria_plugin _maria_plugin_declarations_[]= {
+MYSQL_PLUGIN_EXPORT int _mysql_plugin_interface_version_; \
+int _mysql_plugin_interface_version_= MYSQL_PLUGIN_INTERFACE_VERSION; \
+MYSQL_PLUGIN_EXPORT int _mysql_sizeof_struct_st_plugin_; \
+int _mysql_sizeof_struct_st_plugin_= sizeof(struct st_mysql_plugin); \
+MYSQL_PLUGIN_EXPORT struct st_mysql_plugin _mysql_plugin_declarations_[]; \
+struct st_mysql_plugin _mysql_plugin_declarations_[]= {
+
+#define MARIA_DECLARE_PLUGIN__(NAME, VERSION, PSIZE, DECLS) \
+MYSQL_PLUGIN_EXPORT int _maria_plugin_interface_version_; \
+int _maria_plugin_interface_version_= MARIA_PLUGIN_INTERFACE_VERSION; \
+MYSQL_PLUGIN_EXPORT int _maria_sizeof_struct_st_plugin_; \
+int _maria_sizeof_struct_st_plugin_= sizeof(struct st_maria_plugin); \
+MYSQL_PLUGIN_EXPORT struct st_maria_plugin _maria_plugin_declarations_[]; \
+struct st_maria_plugin _maria_plugin_declarations_[]= {
#endif
diff --git a/include/mysql_com.h b/include/mysql_com.h
index adba1ba141a..171b5eb0463 100644
--- a/include/mysql_com.h
+++ b/include/mysql_com.h
@@ -560,6 +560,7 @@ char *octet2hex(char *to, const char *str, unsigned int len);
/* end of password.c */
char *get_tty_password(const char *opt_message);
+void get_tty_password_buff(const char *opt_message, char *to, size_t length);
const char *mysql_errno_to_sqlstate(unsigned int mysql_errno);
/* Some other useful functions */
diff --git a/include/mysql_embed.h b/include/mysql_embed.h
index b96083d07db..12b18ff965e 100644
--- a/include/mysql_embed.h
+++ b/include/mysql_embed.h
@@ -1,7 +1,8 @@
#ifndef MYSQL_EMBED_INCLUDED
#define MYSQL_EMBED_INCLUDED
-/* Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/mysys_err.h b/include/mysys_err.h
index 42c1bf3175a..f173ccd7a83 100644
--- a/include/mysys_err.h
+++ b/include/mysys_err.h
@@ -1,4 +1,5 @@
-/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2010, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/sslopt-longopts.h b/include/sslopt-longopts.h
index db99d1dfa26..81d03e54016 100644
--- a/include/sslopt-longopts.h
+++ b/include/sslopt-longopts.h
@@ -1,7 +1,8 @@
#ifndef SSLOPT_LONGOPTS_INCLUDED
#define SSLOPT_LONGOPTS_INCLUDED
-/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
+/*
+ Copyright (c) 2000, 2010, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/include/welcome_copyright_notice.h b/include/welcome_copyright_notice.h
index 26c2bb2b097..9e40c17efca 100644
--- a/include/welcome_copyright_notice.h
+++ b/include/welcome_copyright_notice.h
@@ -1,4 +1,4 @@
-/* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
+/* Copyright (c) 2011, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -21,10 +21,6 @@
program on start, or on help screen.
*/
#define ORACLE_WELCOME_COPYRIGHT_NOTICE(years) \
- "Copyright (c) " years ", Oracle and/or its affiliates.\n" \
- "2009-2011 Monty Program Ab\n" \
- "\n" \
- "This software comes with ABSOLUTELY NO WARRANTY. This is free software,\n" \
- "and you are welcome to modify and redistribute it under the GPL license\n"
+ "Copyright (c) " years ", Oracle, Monty Program Ab and others.\n"
#endif /* _welcome_copyright_notice_h_ */