diff options
author | Alexander Nozdrin <alik@sun.com> | 2009-10-23 15:22:21 +0400 |
---|---|---|
committer | Alexander Nozdrin <alik@sun.com> | 2009-10-23 15:22:21 +0400 |
commit | 2dc132b209ef375d7d36a41a2429be001d8e5f45 (patch) | |
tree | 9a94748e3f29d58645ae7979faaf09464080033d /include | |
parent | f3d58bae2011dc043d75268a98e65731da622603 (diff) | |
parent | 75116feb4b8976df3078f288f31fec7f46462461 (diff) | |
download | mariadb-git-2dc132b209ef375d7d36a41a2429be001d8e5f45.tar.gz |
Merge from mysql-next-mr.
Diffstat (limited to 'include')
-rw-r--r-- | include/m_ctype.h | 3 | ||||
-rw-r--r-- | include/my_dbug.h | 6 | ||||
-rw-r--r-- | include/my_global.h | 7 | ||||
-rw-r--r-- | include/my_handler.h | 2 | ||||
-rw-r--r-- | include/my_sys.h | 18 | ||||
-rw-r--r-- | include/myisam.h | 4 |
6 files changed, 25 insertions, 15 deletions
diff --git a/include/m_ctype.h b/include/m_ctype.h index f6503a54935..700f373d677 100644 --- a/include/m_ctype.h +++ b/include/m_ctype.h @@ -477,6 +477,9 @@ uint my_charset_repertoire(CHARSET_INFO *cs); my_bool my_charset_is_ascii_compatible(CHARSET_INFO *cs); +extern size_t my_vsnprintf_ex(CHARSET_INFO *cs, char *to, size_t n, + const char* fmt, va_list ap); + #define _MY_U 01 /* Upper case */ #define _MY_L 02 /* Lower case */ #define _MY_NMR 04 /* Numeral (digit) */ diff --git a/include/my_dbug.h b/include/my_dbug.h index 474a46f29dd..0ba72b2210d 100644 --- a/include/my_dbug.h +++ b/include/my_dbug.h @@ -137,13 +137,13 @@ extern FILE *_db_fp_(void); #define DBUG_EVALUATE_IF(keyword,a1,a2) (a2) #define DBUG_PRINT(keyword,arglist) do { } while(0) #define DBUG_PUSH(a1) -#define DBUG_SET(a1) -#define DBUG_SET_INITIAL(a1) +#define DBUG_SET(a1) do { } while(0) +#define DBUG_SET_INITIAL(a1) do { } while(0) #define DBUG_POP() #define DBUG_PROCESS(a1) #define DBUG_SETJMP(a1) setjmp(a1) #define DBUG_LONGJMP(a1) longjmp(a1) -#define DBUG_DUMP(keyword,a1,a2) +#define DBUG_DUMP(keyword,a1,a2) do { } while(0) #define DBUG_END() #define DBUG_ASSERT(A) do { } while(0) #define DBUG_LOCK_FILE diff --git a/include/my_global.h b/include/my_global.h index 0c02dd6dcac..ca1e1a9d845 100644 --- a/include/my_global.h +++ b/include/my_global.h @@ -410,6 +410,7 @@ C_MODE_END #ifndef stdin #include <stdio.h> #endif +#include <stdarg.h> #ifdef HAVE_STDLIB_H #include <stdlib.h> #endif @@ -558,12 +559,6 @@ int __void__; #define LINT_INIT(var) #endif -#if defined(_lint) || defined(FORCE_INIT_OF_VARS) || defined(HAVE_purify) -#define PURIFY_OR_LINT_INIT(var) var=0 -#else -#define PURIFY_OR_LINT_INIT(var) -#endif - /* Suppress uninitialized variable warning without generating code. diff --git a/include/my_handler.h b/include/my_handler.h index a3376cb74a2..ae56331df86 100644 --- a/include/my_handler.h +++ b/include/my_handler.h @@ -53,8 +53,8 @@ typedef struct st_HA_KEYSEG /* Key-portion */ uint16 bit_pos; /* Position to bit part */ uint16 flag; uint16 length; /* Keylength */ + uint16 language; uint8 type; /* Type of key (for sort) */ - uint8 language; uint8 null_bit; /* bitmask to test for NULL */ uint8 bit_start,bit_end; /* if bit field */ uint8 bit_length; /* Length of bit part */ diff --git a/include/my_sys.h b/include/my_sys.h index 4b93dc0e364..320b7e94467 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -181,6 +181,16 @@ extern char *my_strndup(const char *from, size_t length, #define TRASH(A,B) /* nothing */ #endif +#if defined(ENABLED_DEBUG_SYNC) +extern void (*debug_sync_C_callback_ptr)(const char *, size_t); +#define DEBUG_SYNC_C(_sync_point_name_) do { \ + if (debug_sync_C_callback_ptr != NULL) \ + (*debug_sync_C_callback_ptr)(STRING_WITH_LEN(_sync_point_name_)); } \ + while(0) +#else +#define DEBUG_SYNC_C(_sync_point_name_) +#endif /* defined(ENABLED_DEBUG_SYNC) */ + #ifdef HAVE_LARGE_PAGES extern uint my_get_large_page_size(void); extern uchar * my_large_malloc(size_t size, myf my_flags); @@ -231,8 +241,9 @@ extern uint my_large_page_size; #endif /* charsets */ +#define MY_ALL_CHARSETS_SIZE 2048 extern MYSQL_PLUGIN_IMPORT CHARSET_INFO *default_charset_info; -extern MYSQL_PLUGIN_IMPORT CHARSET_INFO *all_charsets[256]; +extern MYSQL_PLUGIN_IMPORT CHARSET_INFO *all_charsets[MY_ALL_CHARSETS_SIZE]; extern CHARSET_INFO compiled_charsets[]; /* statistics */ @@ -658,6 +669,7 @@ extern void my_osmaperr(unsigned long last_error); extern void TERMINATE(FILE *file, uint flag); #endif extern void init_glob_errs(void); +extern const char** get_global_errmsgs(); extern void wait_for_free_space(const char *filename, int errors); extern FILE *my_fopen(const char *FileName,int Flags,myf MyFlags); extern FILE *my_fdopen(File Filedes,const char *name, int Flags,myf MyFlags); @@ -671,7 +683,8 @@ extern void my_error _VARARGS((int nr,myf MyFlags, ...)); extern void my_printf_error _VARARGS((uint my_err, const char *format, myf MyFlags, ...)) ATTRIBUTE_FORMAT(printf, 2, 4); -extern int my_error_register(const char **errmsgs, int first, int last); +extern int my_error_register(const char** (*get_errmsgs) (), + int first, int last); extern const char **my_error_unregister(int first, int last); extern void my_message(uint my_err, const char *str,myf MyFlags); extern void my_message_no_curses(uint my_err, const char *str,myf MyFlags); @@ -731,7 +744,6 @@ extern int wild_compare(const char *str,const char *wildstr, extern WF_PACK *wf_comp(char * str); extern int wf_test(struct wild_file_pack *wf_pack,const char *name); extern void wf_end(struct wild_file_pack *buffer); -extern size_t strip_sp(char * str); extern my_bool array_append_string_unique(const char *str, const char **array, size_t size); extern void get_date(char * to,int timeflag,time_t use_time); diff --git a/include/myisam.h b/include/myisam.h index 02251eeacb4..70c6f33f118 100644 --- a/include/myisam.h +++ b/include/myisam.h @@ -162,7 +162,7 @@ typedef struct st_mi_create_info ulonglong data_file_length; ulonglong key_file_length; uint old_options; - uint8 language; + uint16 language; my_bool with_auto_increment; } MI_CREATE_INFO; @@ -410,7 +410,7 @@ typedef struct st_mi_check_param uint out_flag,warning_printed,error_printed,verbose; uint opt_sort_key,total_files,max_level; uint testflag, key_cache_block_size; - uint8 language; + uint16 language; my_bool using_global_keycache, opt_lock_memory, opt_follow_links; my_bool retry_repair, force_sort; char temp_filename[FN_REFLEN],*isam_file_name; |