diff options
Diffstat (limited to 'extra')
-rw-r--r--[-rwxr-xr-x] | extra/CMakeLists.txt | 0 | ||||
-rw-r--r-- | extra/Makefile.am | 15 | ||||
-rw-r--r-- | extra/charset2html.c | 2 | ||||
-rw-r--r-- | extra/comp_err.c | 10 | ||||
-rw-r--r-- | extra/perror.c | 12 | ||||
-rw-r--r-- | extra/resolveip.c | 2 | ||||
-rw-r--r--[-rwxr-xr-x] | extra/yassl/CMakeLists.txt | 0 | ||||
-rw-r--r-- | extra/yassl/Makefile.am | 3 | ||||
-rw-r--r-- | extra/yassl/include/lock.hpp | 2 | ||||
-rw-r--r-- | extra/yassl/include/openssl/ssl.h | 1 | ||||
-rw-r--r-- | extra/yassl/include/socket_wrapper.hpp | 5 | ||||
-rw-r--r-- | extra/yassl/include/yassl.hpp | 2 | ||||
-rw-r--r-- | extra/yassl/src/ssl.cpp | 4 | ||||
-rw-r--r--[-rwxr-xr-x] | extra/yassl/taocrypt/CMakeLists.txt | 0 | ||||
-rw-r--r-- | extra/yassl/taocrypt/Makefile.am | 2 | ||||
-rw-r--r-- | extra/yassl/taocrypt/mySTL/algorithm.hpp | 2 |
16 files changed, 35 insertions, 27 deletions
diff --git a/extra/CMakeLists.txt b/extra/CMakeLists.txt index a7a5e3e7b66..a7a5e3e7b66 100755..100644 --- a/extra/CMakeLists.txt +++ b/extra/CMakeLists.txt diff --git a/extra/Makefile.am b/extra/Makefile.am index 6eac67e2979..b2d504cfb62 100644 --- a/extra/Makefile.am +++ b/extra/Makefile.am @@ -14,7 +14,7 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include \ - @ndbcluster_includes@ -I$(top_srcdir)/sql + -I$(top_srcdir)/sql LDADD = @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.a \ ../dbug/libdbug.a ../strings/libmystrings.a \ $(ZLIB_LIBS) @@ -23,10 +23,7 @@ BUILT_SOURCES= $(top_builddir)/include/mysqld_error.h \ $(top_builddir)/include/mysqld_ername.h pkginclude_HEADERS= $(BUILT_SOURCES) DISTCLEANFILES = $(BUILT_SOURCES) -# We never use SUBDIRS here, but needed for automake 1.6.3 -# to generate code to handle DIST_SUBDIRS -SUBDIRS= -DIST_SUBDIRS= yassl +SUBDIRS = @yassl_dir@ # This will build mysqld_error.h, mysqld_ername.h and sql_state.h # NOTE Built files should depend on their sources to avoid @@ -44,10 +41,14 @@ $(top_builddir)/include/mysqld_error.h: comp_err.c \ $(top_builddir)/include/mysqld_ername.h: $(top_builddir)/include/mysqld_error.h $(top_builddir)/include/sql_state.h: $(top_builddir)/include/mysqld_error.h -bin_PROGRAMS = replace comp_err perror resolveip my_print_defaults \ +bin_PROGRAMS = replace perror resolveip my_print_defaults \ resolve_stack_dump mysql_waitpid innochecksum noinst_PROGRAMS = charset2html -EXTRA_DIST = CMakeLists.txt +EXTRA_PROGRAMS = comp_err +EXTRA_DIST = CMakeLists.txt + +perror.o: perror.c + $(COMPILE) @ndbcluster_includes@ $(LM_CFLAGS) -c $< # Don't update the files from bitkeeper %::SCCS/s.% diff --git a/extra/charset2html.c b/extra/charset2html.c index 8795c82bc34..8dcfa0c8990 100644 --- a/extra/charset2html.c +++ b/extra/charset2html.c @@ -153,7 +153,9 @@ int main(int argc, char **argv) { my_init(); if (argc > argcnt && argv[argcnt][0] == '-' && argv[argcnt][1] == '#') + { DBUG_PUSH(argv[argcnt++]+2); + } if (argc > argcnt) the_set = argv[argcnt++]; diff --git a/extra/comp_err.c b/extra/comp_err.c index 7cc4a0aa43f..3f7664405ad 100644 --- a/extra/comp_err.c +++ b/extra/comp_err.c @@ -191,9 +191,9 @@ int main(int argc, char *argv[]) DBUG_RETURN(1); } clean_up(lang_head, error_head); - DBUG_LEAVE; /* we can't call my_end after DBUG_RETURN */ + DBUG_LEAVE; /* Can't use dbug after my_end() */ my_end(info_flag ? MY_CHECK_ERROR | MY_GIVE_INFO : 0); - return(0); + return 0; } } @@ -761,7 +761,7 @@ static char *get_word(char **str) DBUG_ENTER("get_word"); *str= find_end_of_word(start); - DBUG_RETURN(my_strdup_with_length(start, (uint) (*str - start), + DBUG_RETURN(my_strndup(start, (uint) (*str - start), MYF(MY_WME | MY_FAE))); } @@ -795,7 +795,7 @@ static struct message *parse_message_string(struct message *new_message, while (*str != ' ' && *str != '\t' && *str) str++; if (!(new_message->lang_short_name= - my_strdup_with_length(start, (uint) (str - start), + my_strndup(start, (uint) (str - start), MYF(MY_WME | MY_FAE)))) DBUG_RETURN(0); /* Fatal error */ DBUG_PRINT("info", ("msg_slang: %s", new_message->lang_short_name)); @@ -815,7 +815,7 @@ static struct message *parse_message_string(struct message *new_message, start= str + 1; str= parse_text_line(start); - if (!(new_message->text= my_strdup_with_length(start, (uint) (str - start), + if (!(new_message->text= my_strndup(start, (uint) (str - start), MYF(MY_WME | MY_FAE)))) DBUG_RETURN(0); /* Fatal error */ DBUG_PRINT("info", ("msg_text: %s", new_message->text)); diff --git a/extra/perror.c b/extra/perror.c index 4d19f4dd7eb..c49869be681 100644 --- a/extra/perror.c +++ b/extra/perror.c @@ -22,14 +22,14 @@ #include <m_string.h> #include <errno.h> #include <my_getopt.h> -#ifdef HAVE_NDBCLUSTER_DB -#include "../ndb/src/ndbapi/ndberror.c" -#include "../ndb/src/kernel/error/ndbd_exit_codes.c" +#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE +#include "../storage/ndb/src/ndbapi/ndberror.c" +#include "../storage/ndb/src/kernel/error/ndbd_exit_codes.c" #endif static my_bool verbose, print_all_codes; -#ifdef HAVE_NDBCLUSTER_DB +#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE static my_bool ndb_code; static char ndb_string[1024]; #endif @@ -40,7 +40,7 @@ static struct my_option my_long_options[] = NO_ARG, 0, 0, 0, 0, 0, 0}, {"info", 'I', "Synonym for --help.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}, -#ifdef HAVE_NDBCLUSTER_DB +#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE {"ndb", 257, "Ndbcluster storage engine specific error codes.", (gptr*) &ndb_code, (gptr*) &ndb_code, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, #endif @@ -235,7 +235,7 @@ int main(int argc,char *argv[]) found=0; code=atoi(*argv); -#ifdef HAVE_NDBCLUSTER_DB +#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE if (ndb_code) { if ((ndb_error_string(code, ndb_string, sizeof(ndb_string)) < 0) && diff --git a/extra/resolveip.c b/extra/resolveip.c index 1061cafe380..5bbecab5e6b 100644 --- a/extra/resolveip.c +++ b/extra/resolveip.c @@ -31,7 +31,7 @@ #include <my_net.h> #include <my_getopt.h> -#if !defined(_AIX) && !defined(HAVE_UNIXWARE7_THREADS) && !defined(HAVE_UNIXWARE7_POSIX) && !defined(h_errno) +#if !defined(_AIX) && !defined(h_errno) extern int h_errno; #endif diff --git a/extra/yassl/CMakeLists.txt b/extra/yassl/CMakeLists.txt index 5cc97f22a36..5cc97f22a36 100755..100644 --- a/extra/yassl/CMakeLists.txt +++ b/extra/yassl/CMakeLists.txt diff --git a/extra/yassl/Makefile.am b/extra/yassl/Makefile.am index 35946e002c4..1c0e13c511a 100644 --- a/extra/yassl/Makefile.am +++ b/extra/yassl/Makefile.am @@ -1,5 +1,6 @@ SUBDIRS = taocrypt src testsuite -EXTRA_DIST = yassl.dsp yassl.dsw CMakeLists.txt +EXTRA_DIST = yassl.dsp yassl.dsw yassl.vcproj \ + CMakeLists.txt # Don't update the files from bitkeeper %::SCCS/s.% diff --git a/extra/yassl/include/lock.hpp b/extra/yassl/include/lock.hpp index 0525943e45d..b961ec3e478 100644 --- a/extra/yassl/include/lock.hpp +++ b/extra/yassl/include/lock.hpp @@ -28,7 +28,7 @@ namespace yaSSL { #ifdef MULTI_THREADED - #ifdef _WIN32 + #if defined(_WIN32) || defined(_WIN64) #include <windows.h> class Mutex { diff --git a/extra/yassl/include/openssl/ssl.h b/extra/yassl/include/openssl/ssl.h index 29add5ca37d..def7803b725 100644 --- a/extra/yassl/include/openssl/ssl.h +++ b/extra/yassl/include/openssl/ssl.h @@ -191,7 +191,6 @@ enum { /* ERR Constants */ }; - SSL_CTX* SSL_CTX_new(SSL_METHOD*); SSL* SSL_new(SSL_CTX*); int SSL_set_fd (SSL*, int); diff --git a/extra/yassl/include/socket_wrapper.hpp b/extra/yassl/include/socket_wrapper.hpp index 308704c2af0..ba52dbab3ec 100644 --- a/extra/yassl/include/socket_wrapper.hpp +++ b/extra/yassl/include/socket_wrapper.hpp @@ -28,9 +28,8 @@ #include <assert.h> -#ifdef _WIN32 - #include <winsock2.h> -#else +#include "openssl/ssl.h" /* for socket_t */ +#if !defined(_WIN32) && !defined(_WIN64) #include <sys/time.h> #include <sys/types.h> #include <sys/socket.h> diff --git a/extra/yassl/include/yassl.hpp b/extra/yassl/include/yassl.hpp index 29e0a5d94ec..b8190c484f7 100644 --- a/extra/yassl/include/yassl.hpp +++ b/extra/yassl/include/yassl.hpp @@ -28,7 +28,7 @@ namespace yaSSL { -#ifdef _WIN32 +#if defined(_WIN32) || defined(_WIN64) typedef unsigned int SOCKET_T; #else typedef int SOCKET_T; diff --git a/extra/yassl/src/ssl.cpp b/extra/yassl/src/ssl.cpp index 5bbde13a652..860c05a1d25 100644 --- a/extra/yassl/src/ssl.cpp +++ b/extra/yassl/src/ssl.cpp @@ -39,6 +39,7 @@ #include "coding.hpp" // HexDecoder #include "helpers.hpp" // for placement new hack #include <stdio.h> +#include <assert.h> #ifdef _WIN32 #include <windows.h> // FindFirstFile etc.. @@ -58,6 +59,9 @@ int read_file(SSL_CTX* ctx, const char* file, int format, CertType type) if (format != SSL_FILETYPE_ASN1 && format != SSL_FILETYPE_PEM) return SSL_BAD_FILETYPE; + if (file == NULL || !file[0]) + return SSL_BAD_FILE; + FILE* input = fopen(file, "rb"); if (!input) return SSL_BAD_FILE; diff --git a/extra/yassl/taocrypt/CMakeLists.txt b/extra/yassl/taocrypt/CMakeLists.txt index baa8f97dff6..baa8f97dff6 100755..100644 --- a/extra/yassl/taocrypt/CMakeLists.txt +++ b/extra/yassl/taocrypt/CMakeLists.txt diff --git a/extra/yassl/taocrypt/Makefile.am b/extra/yassl/taocrypt/Makefile.am index c03c1a2713b..ac56cfdcf09 100644 --- a/extra/yassl/taocrypt/Makefile.am +++ b/extra/yassl/taocrypt/Makefile.am @@ -1,5 +1,5 @@ SUBDIRS = src test benchmark -EXTRA_DIST = taocrypt.dsw taocrypt.dsp CMakeLists.txt $(wildcard mySTL/*.hpp) +EXTRA_DIST = taocrypt.dsw taocrypt.dsp taocrypt.vcproj CMakeLists.txt $(wildcard mySTL/*.hpp) # Don't update the files from bitkeeper %::SCCS/s.% diff --git a/extra/yassl/taocrypt/mySTL/algorithm.hpp b/extra/yassl/taocrypt/mySTL/algorithm.hpp index d8bc29a0bb9..f6a29cf4bdb 100644 --- a/extra/yassl/taocrypt/mySTL/algorithm.hpp +++ b/extra/yassl/taocrypt/mySTL/algorithm.hpp @@ -27,6 +27,8 @@ namespace mySTL { +#undef max +#undef min template<typename T> inline const T& max(const T& a, const T&b) |