From 97057115962d9dfbe989c799cff089aec5cbcc60 Mon Sep 17 00:00:00 2001 From: Georgi Kodinov Date: Mon, 9 Aug 2010 11:32:50 +0300 Subject: WL#1054: Pluggable authentication support Merged the implementation to a new base tree. --- include/my_sys.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 95689535be5..23c9b2da55f 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -197,7 +197,7 @@ extern void my_large_free(uchar *ptr); #define my_alloca(SZ) alloca((size_t) (SZ)) #define my_afree(PTR) {} #else -#define my_alloca(SZ) my_malloc(SZ,MYF(0)) +#define my_alloca(SZ) my_malloc(SZ,MYF(MY_FAE)) #define my_afree(PTR) my_free(PTR) #endif /* HAVE_ALLOCA */ @@ -824,6 +824,10 @@ extern void set_prealloc_root(MEM_ROOT *root, char *ptr); extern void reset_root_defaults(MEM_ROOT *mem_root, size_t block_size, size_t prealloc_size); extern char *strdup_root(MEM_ROOT *root,const char *str); +static inline char *safe_strdup_root(MEM_ROOT *root, const char *str) +{ + return str ? strdup_root(root, str) : 0; +} extern char *strmake_root(MEM_ROOT *root,const char *str,size_t len); extern void *memdup_root(MEM_ROOT *root,const void *str, size_t len); extern int get_defaults_options(int argc, char **argv, -- cgit v1.2.1 From c0854c3e1746f81abcba27505c7f8adc09ff2c45 Mon Sep 17 00:00:00 2001 From: Mikael Ronstrom Date: Thu, 28 Oct 2010 18:27:25 +0200 Subject: Added reporting of fsync to THD wait interface --- include/my_sys.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 95689535be5..d3bde89e177 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -633,6 +633,8 @@ extern FILE *my_fdopen(File Filedes,const char *name, int Flags,myf MyFlags); extern int my_fclose(FILE *fd,myf MyFlags); extern File my_fileno(FILE *fd); extern int my_chsize(File fd,my_off_t newlength, int filler, myf MyFlags); +void thr_set_sync_wait_callback(void (*before_sync)(void), + void (*after_sync)(void)); extern int my_sync(File fd, myf my_flags); extern int my_sync_dir(const char *dir_name, myf my_flags); extern int my_sync_dir_by_file(const char *file_name, myf my_flags); -- cgit v1.2.1 From f8d2154c30b37817299c37fed39ed7c86b92d052 Mon Sep 17 00:00:00 2001 From: Mats Kindahl Date: Thu, 4 Nov 2010 11:00:59 +0100 Subject: BUG#57108: mysqld crashes when I attempt to install plugin If a relative path is supplied to option --defaults-file or --defaults-extra-file, the server will crash when executing an INSTALL PLUGIN command. The reason is that the defaults file is initially read relative the current working directory when the server is started, but when INSTALL PLUGIN is executed, the server has changed working directory to the data directory. Since there is no check that the call to my_load_defaults() inside mysql_install_plugin(), the subsequence call to free_defaults() will crash the server. This patch fixes the problem by: - Prepending the current working directory to the file name when a relative path is given to the --defaults-file or --defaults- extra-file option the first time my_load_defaults() is called, which is just after the server has started in main(). - Adding a check of the return value of my_load_defaults() inside mysql_install_plugin() and aborting command (with an error) if an error is returned. - It also adds a check of the return value for load_defaults in lib_sql.cc for the embedded server since that was missing. To test that the relative files for the options --defaults-file and --defaults-extra-file is handled properly, mysql-test-run.pl is also changed to not add a --defaults-file option if one is provided in the tests *.opt file. --- include/my_sys.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 23c9b2da55f..7b437e2a745 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -256,7 +256,7 @@ extern my_bool my_disable_locking, my_disable_async_io, extern char wild_many,wild_one,wild_prefix; extern const char *charsets_dir; /* from default.c */ -extern char *my_defaults_extra_file; +extern const char *my_defaults_extra_file; extern const char *my_defaults_group_suffix; extern const char *my_defaults_file; -- cgit v1.2.1 From 3f5a9c7ea03e5c6a62f41bb90f6b1655c59d3d75 Mon Sep 17 00:00:00 2001 From: Alfranio Correia Date: Fri, 5 Nov 2010 17:42:37 +0000 Subject: BUG#57275 binlog_cache_size affects trx- and stmt-cache and gets twice the expected memory After the WL#2687, the binlog_cache_size and max_binlog_cache_size affect both the stmt-cache and the trx-cache. This means that the resource used is twice the amount expected/defined by the user. The binlog_cache_use is incremented when the stmt-cache or the trx-cache is used and binlog_cache_disk_use is incremented when the disk space from the stmt-cache or the trx-cache is used. This behavior does not allow to distinguish which cache may be harming performance due to the extra disk accesses and needs to have its in-memory cache increased. To fix the problem, we introduced two new options and status variables related to the stmt-cache: Options: . binlog_stmt_cache_size . max_binlog_stmt_cache_size Status Variables: . binlog_stmt_cache_use . binlog_stmt_cache_disk_use So there are . binlog_cache_size that defines the size of the transactional cache for updates to transactional engines for the binary log. . binlog_stmt_cache_size that defines the size of the statement cache for updates to non-transactional engines for the binary log. . max_binlog_cache_size that sets the total size of the transactional cache. . max_binlog_stmt_cache_size that sets the total size of the statement cache. . binlog_cache_use that identifies the number of transactions that used the temporary transactional binary log cache. . binlog_cache_disk_use that identifies the number of transactions that used the temporary transactional binary log cache but that exceeded the value of binlog_cache_size. . binlog_stmt_cache_use that identifies the number of statements that used the temporary non-transactional binary log cache. . binlog_stmt_cache_disk_use that identifies the number of statements that used the temporary non-transactional binary log cache but that exceeded the value of binlog_stmt_cache_size. include/my_sys.h: Updated message on disk_writes' usage. mysql-test/extra/binlog_tests/binlog_cache_stat.test: Updated the test case and added code to check the new status variables binlog_stmt_cache_use and binlog_stmt_cache_disk_use. mysql-test/extra/rpl_tests/rpl_binlog_max_cache_size.test: Updated the test case to use the new system variables max_binlog_stmt_cache_size and binlog_stmt_cache_size. mysql-test/r/mysqld--help-notwin.result: Updated the result file. mysql-test/suite/binlog/r/binlog_mixed_cache_stat.result: Updated the result file. mysql-test/suite/binlog/r/binlog_row_cache_stat.result: Updated the result file. mysql-test/suite/binlog/r/binlog_stm_cache_stat.result: Updated the result file. mysql-test/suite/rpl/r/rpl_mixed_binlog_max_cache_size.result: Update the result file. mysql-test/suite/rpl/r/rpl_row_binlog_max_cache_size.result: Update the result file. mysql-test/suite/rpl/r/rpl_stm_binlog_max_cache_size.result: Updated the result file. mysql-test/suite/sys_vars/inc/binlog_stmt_cache_size_basic.inc: Added a test case to check the binlog_stmt_cache_size. mysql-test/suite/sys_vars/r/binlog_stmt_cache_size_basic_32.result: Updated the result file. mysql-test/suite/sys_vars/r/binlog_stmt_cache_size_basic_64.result: Updated the result file. mysql-test/suite/sys_vars/r/max_binlog_stmt_cache_size_basic.result: Updated the result file. mysql-test/suite/sys_vars/t/binlog_stmt_cache_size_basic_32.test: Added a test case to check the binlog_stmt_cache_size. mysql-test/suite/sys_vars/t/binlog_stmt_cache_size_basic_64.test: Added a test case to check the binlog_stmt_cache_size. mysql-test/suite/sys_vars/t/max_binlog_cache_size_func-master.opt: Removed because there is no test case max_binlog_cache_size_func. mysql-test/suite/sys_vars/t/max_binlog_stmt_cache_size_basic.test: Added a test case to check the system variable max_binlog_stmt_cache_size. sql/log.cc: There two main changes in here: . Changed the set_write_error() as an error message is set according to the type of the cache. . Created the function set_binlog_cache_info where references to the appropriate status and system variables are set and the server can smoothly compute statistics and set the maximum size for each cache. sql/log.h: Changed the signature of the function in order to identify the error message to be printed out as there is a different error code for each type of cache. sql/mysqld.cc: Added new status variables binlog_stmt_cache_use and binlog_stmt_cache_disk_use. sql/mysqld.h: Added new system variables max_binlog_stmt_cache_size and binlog_stmt_cache_size. sql/share/errmsg-utf8.txt: Added new error message related to the statement cache. sql/sys_vars.cc: Added new system variables max_binlog_stmt_cache_size and binlog_stmt_cache_size. --- include/my_sys.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 23c9b2da55f..c50f014b88c 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -456,7 +456,8 @@ typedef struct st_io_cache /* Used when cacheing files */ IO_CACHE_CALLBACK pre_close; /* Counts the number of times, when we were forced to use disk. We use it to - increase the binlog_cache_disk_use status variable. + increase the binlog_cache_disk_use and binlog_stmt_cache_disk_use status + variables. */ ulong disk_writes; void* arg; /* for use by pre/post_read */ -- cgit v1.2.1 From 85323eda8a5823e4db1fa34dc998684b67e710b5 Mon Sep 17 00:00:00 2001 From: Kent Boortz Date: Tue, 28 Dec 2010 19:57:23 +0100 Subject: - Added/updated copyright headers - Removed files specific to compiling on OS/2 - Removed files specific to SCO Unix packaging - Removed "libmysqld/copyright", text is included in documentation - Removed LaTeX headers for NDB Doxygen documentation - Removed obsolete NDB files - Removed "mkisofs" binaries - Removed the "cvs2cl.pl" script - Changed a few GPL texts to use "program" instead of "library" --- include/my_sys.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 40ae6924f9f..93cab0852f7 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2000-2003 MySQL AB +/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. 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 -- cgit v1.2.1 From c5aa3313aa44c13e40875a8e2fae01db26377c59 Mon Sep 17 00:00:00 2001 From: He Zhenxing Date: Mon, 17 Jan 2011 15:44:37 +0800 Subject: BUG#57953 my_load_defaults return junk argument ----args-separator---- to caller After fix of bug#25192, load_defaults() will add an args separator to distinguish options loaded from configure files from that provided in the command line. One problem of this is that the args separator would be added no matter the application need it or not. Fixed the problem by adding an option: bool my_getopt_use_args_separator; to control whether the separator will be added or not. And also added functions: bool my_getopt_is_args_separator(const char* arg); to check if the argument is the separator or not. --- include/my_sys.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 96b40415c56..484dc684b03 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -817,7 +817,8 @@ extern void *memdup_root(MEM_ROOT *root,const void *str, size_t len); extern int get_defaults_options(int argc, char **argv, char **defaults, char **extra_defaults, char **group_suffix); -extern const char *args_separator; +extern my_bool my_getopt_use_args_separator; +extern my_bool my_getopt_is_args_separator(const char* arg); extern int my_load_defaults(const char *conf_file, const char **groups, int *argc, char ***argv, const char ***); extern int load_defaults(const char *conf_file, const char **groups, -- cgit v1.2.1 From 998065c3a6f3d65e88c3926b31088a245f77406d Mon Sep 17 00:00:00 2001 From: Davi Arnaut Date: Fri, 7 Jan 2011 16:33:36 -0200 Subject: Bug#51023: Mysql server crashes on SIGHUP and destroys InnoDB files From a user perspective, the problem is that a FLUSH LOGS or SIGHUP signal could end up associating the stdout and stderr to random files. In the case of this bug report, the streams would end up associated to InnoDB ibd files. The freopen(3) function is not thread-safe on FreeBSD. What this means is that if another thread calls open(2) during freopen() is executing that another thread's fd returned by open(2) may get re-associated with the file being passed to freopen(3). See FreeBSD PR number 79887 for reference: http://www.freebsd.org/cgi/query-pr.cgi?pr=79887 This problem is worked around by substituting a internal hook within the FILE structure. This avoids the loss of atomicity by not having the original fd closed before its duplicated. Patch based on the original work by Vasil Dimov. include/my_sys.h: Export my_freopen. mysys/my_fopen.c: Add a my_freopen abstraction to workaround bugs in specific OSes. Add a prototype for getosreldate() as older FreeBSD versions did not define one. sql/log.cc: Move freopen abstraction code over to mysys. The streams are now only reopened for writing. --- include/my_sys.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 90fd78f77ba..0ac220cec31 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -664,6 +664,7 @@ extern void init_glob_errs(void); 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); +extern FILE *my_freopen(const char *path, const char *mode, FILE *stream); extern int my_fclose(FILE *fd,myf MyFlags); extern int my_chsize(File fd,my_off_t newlength, int filler, myf MyFlags); extern int my_sync(File fd, myf my_flags); -- cgit v1.2.1 From 8ede0759c30bb49025b466a69951d5f36d2b6b92 Mon Sep 17 00:00:00 2001 From: Magne Mahre Date: Tue, 11 Jan 2011 10:07:37 +0100 Subject: Remove configuration preprocessor symbols 'THREAD' and 'THREAD_SAFE_CLIENT'. As of MySQL 5.5, we no longer support non-threaded builds. This patch removes all references to the obsolete THREAD and THREAD_SAFE_CLIENT preprocessor symbols. These were used to distinguish between threaded and non-threaded builds. --- include/my_sys.h | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 8f7d5b0925d..96b40415c56 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -41,11 +41,7 @@ typedef struct my_aio_result { # define MEM_CHECK_DEFINED(a,len) ((void) 0) #endif /* HAVE_VALGRIND */ -#ifndef THREAD -extern int my_errno; /* Last error in mysys */ -#else #include -#endif #include /* for CHARSET_INFO */ #include @@ -314,7 +310,7 @@ struct st_my_file_info int oflag; /* open flags, e.g O_APPEND */ #endif enum file_type type; -#if defined(THREAD) && !defined(HAVE_PREAD) && !defined(_WIN32) +#if !defined(HAVE_PREAD) && !defined(_WIN32) mysql_mutex_t mutex; #endif }; @@ -334,9 +330,7 @@ typedef struct st_my_tmpdir DYNAMIC_ARRAY full_list; char **list; uint cur, max; -#ifdef THREAD mysql_mutex_t mutex; -#endif } MY_TMPDIR; typedef struct st_dynamic_string @@ -348,7 +342,6 @@ typedef struct st_dynamic_string struct st_io_cache; typedef int (*IO_CACHE_CALLBACK)(struct st_io_cache*); -#ifdef THREAD typedef struct st_io_cache_share { mysql_mutex_t mutex; /* To sync on reads into buffer. */ @@ -368,7 +361,6 @@ typedef struct st_io_cache_share my_bool alloced; #endif } IO_CACHE_SHARE; -#endif typedef struct st_io_cache /* Used when cacheing files */ { @@ -409,7 +401,7 @@ typedef struct st_io_cache /* Used when cacheing files */ WRITE_CACHE, and &read_pos and &read_end respectively otherwise */ uchar **current_pos, **current_end; -#ifdef THREAD + /* The lock is for append buffer used in SEQ_READ_APPEND cache need mutex copying from append buffer to read buffer. @@ -423,7 +415,7 @@ typedef struct st_io_cache /* Used when cacheing files */ READ_CACHE mode is supported. */ IO_CACHE_SHARE *share; -#endif + /* A caller will use my_b_read() macro to read from the cache if the data is already in cache, it will be simply copied with @@ -656,14 +648,6 @@ extern int my_redel(const char *from, const char *to, int MyFlags); extern int my_copystat(const char *from, const char *to, int MyFlags); extern char * my_filename(File fd); -#ifndef THREAD -extern void dont_break(void); -extern void allow_break(void); -#else -#define dont_break() -#define allow_break() -#endif - #ifdef EXTRA_DEBUG void my_print_open_files(void); #else @@ -736,12 +720,10 @@ extern my_bool reinit_io_cache(IO_CACHE *info,enum cache_type type, pbool clear_cache); extern void setup_io_cache(IO_CACHE* info); extern int _my_b_read(IO_CACHE *info,uchar *Buffer,size_t Count); -#ifdef THREAD extern int _my_b_read_r(IO_CACHE *info,uchar *Buffer,size_t Count); extern void init_io_cache_share(IO_CACHE *read_cache, IO_CACHE_SHARE *cshare, IO_CACHE *write_cache, uint num_threads); extern void remove_io_thread(IO_CACHE *info); -#endif extern int _my_b_seq_read(IO_CACHE *info,uchar *Buffer,size_t Count); extern int _my_b_net_read(IO_CACHE *info,uchar *Buffer,size_t Count); extern int _my_b_get(IO_CACHE *info); -- cgit v1.2.1 From c711ce6726102a2c4872e1bd6918e2a9772b7c2d Mon Sep 17 00:00:00 2001 From: Tor Didriksen Date: Wed, 2 Feb 2011 12:54:49 +0100 Subject: Bug #36022 please log more information about "Sort aborted" queries Write an additional warning message to the server log, explaining why a sort operation is aborted. The output in mysqld.err will look something like: 110127 15:07:54 [ERROR] mysqld: Sort aborted: Out of memory (Needed 24 bytes) 110127 15:07:54 [ERROR] mysqld: Out of sort memory, consider increasing server sort buffer size 110127 15:07:54 [ERROR] mysqld: Sort aborted: Out of sort memory, consider increasing server sort buffer size 110127 15:07:54 [ERROR] mysqld: Sort aborted: Incorrect number of arguments for FUNCTION test.f1; expected 0, got 1 If --log-warn=2 is enabled, we output information about host/user/query as well. include/my_sys.h: Update comment for ME_NOREFRESH mysql-test/include/mtr_warnings.sql: Remove global filtering of "Out of sort memory", let each individual test set it instead. mysql-test/r/filesort_debug.result: New test case. mysql-test/r/order_by.result: Ignore "Out of memory" for this test. mysql-test/t/filesort_debug.test: New test case. mysql-test/t/order_by.test: Ignore "Out of memory" for this test. sql/filesort.cc: Output an explanation using the error message from the THD Diagnostics_area. sql/protocol.cc: Do not DBUG_RETURN(function_call_with DBUG_RETURN) as it messes up the call stack in the debug output. sql/share/errmsg-utf8.txt: Change error message for "Out of sort memory" sql/unireg.h: Remove unused/confusing ERRMAPP macro. --- include/my_sys.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index 484dc684b03..fb8fa6e7a3e 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. +/* Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved. 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 @@ -104,7 +104,7 @@ typedef struct my_aio_result { #define ME_HOLDTANG 8 /* Don't delete last keys */ #define ME_WAITTOT 16 /* Wait for errtime secs of for a action */ #define ME_WAITTANG 32 /* Wait for a user action */ -#define ME_NOREFRESH 64 /* Dont refresh screen */ +#define ME_NOREFRESH 64 /* Write the error message to error log */ #define ME_NOINPUT 128 /* Dont use the input libary */ #define ME_COLOUR1 ((1 << ME_HIGHBYTE)) /* Possibly error-colours */ #define ME_COLOUR2 ((2 << ME_HIGHBYTE)) -- cgit v1.2.1 From c4715a807690d68c5dfe3f8e36e2ac916d9f37a5 Mon Sep 17 00:00:00 2001 From: Magne Mahre Date: Tue, 1 Mar 2011 13:03:31 +0100 Subject: Bug#11765237 - 58179: CANNOT START MYSQLD WITH APP VERIFIER Bug#11763065 - 55730: KILL_SERVER() CALLS SETEVENT ON A NULL HANDLE, SMEM_EVENT_CONNECT_REQUEST Application Verifier is a Microsoft tool used for detecting certain classes of programming errors. In particular, MS Windows OS resource usage is monitored for wrong usage (handles, thread local storage, critical sections, ...) In MySQL 5.5.x, an error was introduced where an object on thread local storage was used before the TLS and the object was created. The fix has been to move the mysys initialization to an earlier stage in the boot process when built for Windows. For non-win builds, the init already happens early. Some un-tangling of calls to my_init(), my_basic_init() and my_thread_global_init() was done. There is no longer a need to do init in steps, so the full my_init() is called instead of my_init_basic(). In addition, Bug#11763065 was fixed. The event handle 'smem_event_connect_request' is only created if 'opt_enable_shared_memory' is set. When killing the server, an event was flagged on the handle unconditionally. Added a test, so it will only be flagged if created. include/my_pthread.h: my_thread_basic_global_init is no longer necessary, and the my_thread_basic_global_reinit function is renamed to reflect that it now reinits mutexes and condvars originating from my_thread_global_init mysys/my_thr_init.c: Reorganized code. --- include/my_sys.h | 1 - 1 file changed, 1 deletion(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index fb8fa6e7a3e..f0b2c1a0636 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -641,7 +641,6 @@ extern int my_error_register(const char** (*get_errmsgs) (), 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_stderr(uint my_err, const char *str, myf MyFlags); -extern my_bool my_basic_init(void); extern my_bool my_init(void); extern void my_end(int infoflag); extern int my_redel(const char *from, const char *to, int MyFlags); -- cgit v1.2.1 From b14adc3921d3f2e30f858a31ae73ecdc65901e54 Mon Sep 17 00:00:00 2001 From: Mikael Ronstrom Date: Fri, 4 Mar 2011 13:12:31 +0100 Subject: More review fixes --- include/my_sys.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/my_sys.h') diff --git a/include/my_sys.h b/include/my_sys.h index ed96abc7711..e13ef1af067 100644 --- a/include/my_sys.h +++ b/include/my_sys.h @@ -627,8 +627,8 @@ extern FILE *my_freopen(const char *path, const char *mode, FILE *stream); extern int my_fclose(FILE *fd,myf MyFlags); extern File my_fileno(FILE *fd); extern int my_chsize(File fd,my_off_t newlength, int filler, myf MyFlags); -void thr_set_sync_wait_callback(void (*before_sync)(void), - void (*after_sync)(void)); +extern void thr_set_sync_wait_callback(void (*before_sync)(void), + void (*after_sync)(void)); extern int my_sync(File fd, myf my_flags); extern int my_sync_dir(const char *dir_name, myf my_flags); extern int my_sync_dir_by_file(const char *file_name, myf my_flags); -- cgit v1.2.1