|
Defines |
#define | MYSYS_PROGRAM_USES_CURSES() { error_handler_hook = my_message_curses; mysys_uses_curses=1; } |
#define | MYSYS_PROGRAM_DONT_USE_CURSES() { error_handler_hook = my_message_no_curses; mysys_uses_curses=0;} |
#define | MY_INIT(name) ; { my_progname= name; my_init(); } |
#define | MAXMAPS (4) |
#define | ERRMOD (1000) |
#define | ERRMSGSIZE (SC_MAXWIDTH) |
#define | NRERRBUFFS (2) |
#define | MY_FILE_ERROR ((uint) ~0) |
#define | MY_FFNF 1 |
#define | MY_FNABP 2 |
#define | MY_NABP 4 |
#define | MY_FAE 8 |
#define | MY_WME 16 |
#define | MY_WAIT_IF_FULL 32 |
#define | MY_RAID 64 |
#define | MY_FULL_IO 512 |
#define | MY_DONT_CHECK_FILESIZE 128 |
#define | MY_LINK_WARNING 32 |
#define | MY_COPYTIME 64 |
#define | MY_DELETE_OLD 256 |
#define | MY_RESOLVE_LINK 128 |
#define | MY_HOLD_ORIGINAL_MODES 128 |
#define | MY_REDEL_MAKE_BACKUP 256 |
#define | MY_SEEK_NOT_DONE 32 |
#define | MY_DONT_WAIT 64 |
#define | MY_ZEROFILL 32 |
#define | MY_ALLOW_ZERO_PTR 64 |
#define | MY_FREE_ON_ERROR 128 |
#define | MY_HOLD_ON_ERROR 256 |
#define | MY_THREADSAFE 128 |
#define | MY_DONT_OVERWRITE_FILE 1024 |
#define | MY_CHECK_ERROR 1 |
#define | MY_GIVE_INFO 2 |
#define | ME_HIGHBYTE 8 |
#define | ME_NOCUR 1 |
#define | ME_OLDWIN 2 |
#define | ME_BELL 4 |
#define | ME_HOLDTANG 8 |
#define | ME_WAITTOT 16 |
#define | ME_WAITTANG 32 |
#define | ME_NOREFRESH 64 |
#define | ME_NOINPUT 128 |
#define | ME_COLOUR1 ((1 << ME_HIGHBYTE)) |
#define | ME_COLOUR2 ((2 << ME_HIGHBYTE)) |
#define | ME_COLOUR3 ((3 << ME_HIGHBYTE)) |
#define | MY_REPLACE_DIR 1 |
#define | MY_REPLACE_EXT 2 |
#define | MY_UNPACK_FILENAME 4 |
#define | MY_PACK_FILENAME 8 |
#define | MY_RESOLVE_SYMLINKS 16 |
#define | MY_RETURN_REAL_PATH 32 |
#define | MY_SAFE_PATH 64 |
#define | MY_RELATIVE_PATH 128 |
#define | MY_SEEK_SET 0 |
#define | MY_SEEK_CUR 1 |
#define | MY_SEEK_END 2 |
#define | MY_WAIT_FOR_USER_TO_FIX_PANIC 60 |
#define | MY_WAIT_GIVE_USER_A_MESSAGE 10 |
#define | MIN_COMPRESS_LENGTH 50 |
#define | DFLT_INIT_HITS 3 |
#define | MY_KEEP_PREALLOC 1 |
#define | MY_MARK_BLOCKS_FREE 2 |
#define | MY_ERRNO_EDOM 33 |
#define | MY_ERRNO_ERANGE 34 |
#define | my_checkmalloc() |
#define | TERMINATE(A) {} |
#define | QUICK_SAFEMALLOC |
#define | NORMAL_SAFEMALLOC |
#define | my_malloc_ci(SZ, FLAG) my_malloc( SZ, FLAG ) |
#define | my_free(PTR, FG) my_no_flags_free(PTR) |
#define | CALLER_INFO_PROTO |
#define | CALLER_INFO |
#define | ORIG_CALLER_INFO |
#define | my_alloca(SZ) my_malloc(SZ,MYF(0)) |
#define | my_afree(PTR) my_free(PTR,MYF(MY_WME)) |
#define | my_b_clear(info) (info)->buffer=0 |
#define | my_b_inited(info) (info)->buffer |
#define | my_b_EOF INT_MIN |
#define | my_b_read(info, Buffer, Count) |
#define | my_b_write(info, Buffer, Count) |
#define | my_b_get(info) |
#define | my_b_write_byte(info, chr) |
#define | my_b_fill_cache(info) (((info)->read_end=(info)->read_pos),(*(info)->read_function)(info,0,0)) |
#define | my_b_tell(info) |
#define | my_b_bytes_in_cache(info) |
#define | my_access access |
#define | base_name(A) (A+dirname_length(A)) |
#define | flush_io_cache(info) my_b_flush_io_cache((info),1) |
#define | my_init_dynamic_array(A, B, C, D) init_dynamic_array(A,B,C,D CALLER_INFO) |
#define | my_init_dynamic_array_ci(A, B, C, D) init_dynamic_array(A,B,C,D ORIG_CALLER_INFO) |
#define | dynamic_array_ptr(array, array_index) ((array)->buffer+(array_index)*(array)->size_of_element) |
#define | dynamic_element(array, array_index, type) ((type)((array)->buffer) +(array_index)) |
#define | push_dynamic(A, B) insert_dynamic(A,B) |
#define | reset_dynamic(array) ((array)->elements= 0) |
#define | my_malloc_lock(A, B) my_malloc((A),(B)) |
#define | my_free_lock(A, B) my_free((A),(B)) |
#define | alloc_root_inited(A) ((A)->min_malloc != 0) |
#define | ALLOC_ROOT_MIN_BLOCK_SIZE (MALLOC_OVERHEAD + sizeof(USED_MEM) + 8) |
#define | clear_alloc_root(A) do { (A)->free= (A)->used= (A)->pre_alloc= 0; (A)->min_malloc=0;} while(0) |
Typedefs |
typedef wild_file_pack | WF_PACK |
typedef st_record_cache | RECORD_CACHE |
typedef st_my_tmpdir | MY_TMPDIR |
typedef st_dynamic_array | DYNAMIC_ARRAY |
typedef st_dynamic_string | DYNAMIC_STRING |
typedef int(* | IO_CACHE_CALLBACK )(struct st_io_cache *) |
typedef st_io_cache | IO_CACHE |
typedef int(* | qsort2_cmp )(const void *, const void *, const void *) |
typedef uint32 | ha_checksum |
Enumerations |
enum | loglevel { ERROR_LEVEL,
WARNING_LEVEL,
INFORMATION_LEVEL
} |
enum | cache_type {
READ_CACHE,
WRITE_CACHE,
SEQ_READ_APPEND,
READ_FIFO,
READ_NET,
WRITE_NET
} |
enum | flush_type { FLUSH_KEEP,
FLUSH_RELEASE,
FLUSH_IGNORE_CHANGED,
FLUSH_FORCE_WRITE
} |
enum | file_type {
UNOPEN = 0,
FILE_BY_OPEN,
FILE_BY_CREATE,
STREAM_BY_FOPEN,
STREAM_BY_FDOPEN,
FILE_BY_MKSTEMP,
FILE_BY_DUP
} |
Functions |
gptr | my_malloc (uint Size, myf MyFlags) |
gptr | my_realloc (gptr oldpoint, uint Size, myf MyFlags) |
void | my_no_flags_free (gptr ptr) |
gptr | my_memdup (const byte *from, uint length, myf MyFlags) |
char * | my_strdup (const char *from, myf MyFlags) |
char * | my_strdup_with_length (const byte *from, uint length, myf MyFlags) |
void(*)(*) | my_sigtstp_restart (void) |
my_off_t | my_b_append_tell (IO_CACHE *info) |
int | my_copy (const char *from, const char *to, myf MyFlags) |
int | my_append (const char *from, const char *to, myf MyFlags) |
int | my_delete (const char *name, myf MyFlags) |
int | my_getwd (my_string buf, uint size, myf MyFlags) |
int | my_setwd (const char *dir, myf MyFlags) |
int | my_lock (File fd, int op, my_off_t start, my_off_t length, myf MyFlags) |
gptr | my_once_alloc (uint Size, myf MyFlags) |
void | my_once_free (void) |
char * | my_once_strdup (const char *src, myf myflags) |
char * | my_once_memdup (const char *src, uint len, myf myflags) |
my_string | my_tempnam (const char *dir, const char *pfx, myf MyFlags) |
File | my_open (const char *FileName, int Flags, myf MyFlags) |
File | my_register_filename (File fd, const char *FileName, enum file_type type_of_file, uint error_message_number, myf MyFlags) |
File | my_create (const char *FileName, int CreateFlags, int AccsesFlags, myf MyFlags) |
int | my_close (File Filedes, myf MyFlags) |
File | my_dup (File file, myf MyFlags) |
int | my_mkdir (const char *dir, int Flags, myf MyFlags) |
int | my_readlink (char *to, const char *filename, myf MyFlags) |
int | my_realpath (char *to, const char *filename, myf MyFlags) |
File | my_create_with_symlink (const char *linkname, const char *filename, int createflags, int access_flags, myf MyFlags) |
int | my_delete_with_symlink (const char *name, myf MyFlags) |
int | my_rename_with_symlink (const char *from, const char *to, myf MyFlags) |
int | my_symlink (const char *content, const char *linkname, myf MyFlags) |
uint | my_read (File Filedes, byte *Buffer, uint Count, myf MyFlags) |
uint | my_pread (File Filedes, byte *Buffer, uint Count, my_off_t offset, myf MyFlags) |
int | my_rename (const char *from, const char *to, myf MyFlags) |
my_off_t | my_seek (File fd, my_off_t pos, int whence, myf MyFlags) |
my_off_t | my_tell (File fd, myf MyFlags) |
uint | my_write (File Filedes, const byte *Buffer, uint Count, myf MyFlags) |
uint | my_pwrite (File Filedes, const byte *Buffer, uint Count, my_off_t offset, myf MyFlags) |
uint | my_fread (FILE *stream, byte *Buffer, uint Count, myf MyFlags) |
uint | my_fwrite (FILE *stream, const byte *Buffer, uint Count, myf MyFlags) |
my_off_t | my_fseek (FILE *stream, my_off_t pos, int whence, myf MyFlags) |
my_off_t | my_ftell (FILE *stream, myf MyFlags) |
gptr | _mymalloc (uint uSize, const char *sFile, uint uLine, myf MyFlag) |
gptr | _myrealloc (gptr pPtr, uint uSize, const char *sFile, uint uLine, myf MyFlag) |
gptr my_multi_malloc | _VARARGS ((myf MyFlags,...)) |
void | _myfree (gptr pPtr, const char *sFile, uint uLine, myf MyFlag) |
int | _sanity (const char *sFile, unsigned int uLine) |
gptr | _my_memdup (const byte *from, uint length, const char *sFile, uint uLine, myf MyFlag) |
my_string | _my_strdup (const char *from, const char *sFile, uint uLine, myf MyFlag) |
char * | _my_strdup_with_length (const byte *from, uint length, const char *sFile, uint uLine, myf MyFlag) |
int | check_if_legal_filename (const char *path) |
void | init_glob_errs (void) |
FILE * | my_fopen (const char *FileName, int Flags, myf MyFlags) |
FILE * | my_fdopen (File Filedes, const char *name, int Flags, myf MyFlags) |
int | my_fclose (FILE *fd, myf MyFlags) |
int | my_chsize (File fd, my_off_t newlength, int filler, myf MyFlags) |
int | my_sync (File fd, myf my_flags) |
int my_error | _VARARGS ((int nr, myf MyFlags,...)) |
int my_printf_error | _VARARGS ((uint my_err, const char *format, myf MyFlags,...) __attribute__((format(printf, 2, 4)))) |
int | my_message (uint my_err, const char *str, myf MyFlags) |
int | my_message_no_curses (uint my_err, const char *str, myf MyFlags) |
int | my_message_curses (uint my_err, const char *str, myf MyFlags) |
my_bool | my_init (void) |
void | my_end (int infoflag) |
int | my_redel (const char *from, const char *to, int MyFlags) |
int | my_copystat (const char *from, const char *to, int MyFlags) |
my_string | my_filename (File fd) |
void | dont_break (void) |
void | allow_break (void) |
my_bool | init_tmpdir (MY_TMPDIR *tmpdir, const char *pathlist) |
char * | my_tmpdir (MY_TMPDIR *tmpdir) |
void | free_tmpdir (MY_TMPDIR *tmpdir) |
void | my_remember_signal (int signal_number, sig_handler(*func)(int)) |
uint | dirname_part (my_string to, const char *name) |
uint | dirname_length (const char *name) |
int | test_if_hard_path (const char *dir_name) |
my_bool | has_path (const char *name) |
char * | convert_dirname (char *to, const char *from, const char *from_end) |
void | to_unix_path (my_string name) |
my_string | fn_ext (const char *name) |
my_string | fn_same (my_string toname, const char *name, int flag) |
my_string | fn_format (my_string to, const char *name, const char *dir, const char *form, uint flag) |
size_s | strlength (const char *str) |
void | pack_dirname (my_string to, const char *from) |
uint | unpack_dirname (my_string to, const char *from) |
uint | cleanup_dirname (my_string to, const char *from) |
uint | system_filename (my_string to, const char *from) |
uint | unpack_filename (my_string to, const char *from) |
my_string | intern_filename (my_string to, const char *from) |
my_string | directory_file_name (my_string dst, const char *src) |
int | pack_filename (my_string to, const char *name, size_s max_length) |
my_string | my_path (my_string to, const char *progname, const char *own_pathname_part) |
my_string | my_load_path (my_string to, const char *path, const char *own_path_prefix) |
int | wild_compare (const char *str, const char *wildstr, pbool str_is_pattern) |
WF_PACK * | wf_comp (my_string str) |
int | wf_test (struct wild_file_pack *wf_pack, const char *name) |
void | wf_end (struct wild_file_pack *buffer) |
size_s | strip_sp (my_string str) |
void | get_date (my_string to, int timeflag, time_t use_time) |
void | soundex (CHARSET_INFO *, my_string out_pntr, my_string in_pntr, pbool remove_garbage) |
int | init_record_cache (RECORD_CACHE *info, uint cachesize, File file, uint reclength, enum cache_type type, pbool use_async_io) |
int | read_cache_record (RECORD_CACHE *info, byte *to) |
int | end_record_cache (RECORD_CACHE *info) |
int | write_cache_record (RECORD_CACHE *info, my_off_t filepos, const byte *record, uint length) |
int | flush_write_cache (RECORD_CACHE *info) |
long | my_clock (void) |
sig_handler | sigtstp_handler (int signal_number) |
void | handle_recived_signals (void) |
sig_handler | my_set_alarm_variable (int signo) |
void | my_string_ptr_sort (void *base, uint items, size_s size) |
void | radixsort_for_str_ptr (uchar *base[], uint number_of_elements, size_s size_of_element, uchar *buffer[]) |
qsort_t | qsort2 (void *base_ptr, size_t total_elems, size_t size, qsort2_cmp cmp, void *cmp_argument) |
qsort2_cmp | get_ptr_compare (uint) |
int | init_io_cache (IO_CACHE *info, File file, uint cachesize, enum cache_type type, my_off_t seek_offset, pbool use_async_io, myf cache_myflags) |
my_bool | reinit_io_cache (IO_CACHE *info, enum cache_type type, my_off_t seek_offset, pbool use_async_io, pbool clear_cache) |
void | setup_io_cache (IO_CACHE *info) |
int | _my_b_read (IO_CACHE *info, byte *Buffer, uint Count) |
int | _my_b_seq_read (IO_CACHE *info, byte *Buffer, uint Count) |
int | _my_b_net_read (IO_CACHE *info, byte *Buffer, uint Count) |
int | _my_b_get (IO_CACHE *info) |
int | _my_b_async_read (IO_CACHE *info, byte *Buffer, uint Count) |
int | _my_b_write (IO_CACHE *info, const byte *Buffer, uint Count) |
int | my_b_append (IO_CACHE *info, const byte *Buffer, uint Count) |
int | my_b_safe_write (IO_CACHE *info, const byte *Buffer, uint Count) |
int | my_block_write (IO_CACHE *info, const byte *Buffer, uint Count, my_off_t pos) |
int | my_b_flush_io_cache (IO_CACHE *info, int need_append_buffer_lock) |
int | end_io_cache (IO_CACHE *info) |
uint | my_b_fill (IO_CACHE *info) |
void | my_b_seek (IO_CACHE *info, my_off_t pos) |
uint | my_b_gets (IO_CACHE *info, char *to, uint max_length) |
my_off_t | my_b_filelength (IO_CACHE *info) |
uint | my_b_printf (IO_CACHE *info, const char *fmt,...) |
uint | my_b_vprintf (IO_CACHE *info, const char *fmt, va_list ap) |
my_bool | open_cached_file (IO_CACHE *cache, const char *dir, const char *prefix, uint cache_size, myf cache_myflags) |
my_bool | real_open_cached_file (IO_CACHE *cache) |
void | close_cached_file (IO_CACHE *cache) |
File | create_temp_file (char *to, const char *dir, const char *pfx, int mode, myf MyFlags) |
my_bool | init_dynamic_array (DYNAMIC_ARRAY *array, uint element_size, uint init_alloc, uint alloc_increment CALLER_INFO_PROTO) |
my_bool | insert_dynamic (DYNAMIC_ARRAY *array, gptr element) |
byte * | alloc_dynamic (DYNAMIC_ARRAY *array) |
byte * | pop_dynamic (DYNAMIC_ARRAY *) |
my_bool | set_dynamic (DYNAMIC_ARRAY *array, gptr element, uint array_index) |
void | get_dynamic (DYNAMIC_ARRAY *array, gptr element, uint array_index) |
void | delete_dynamic (DYNAMIC_ARRAY *array) |
void | delete_dynamic_element (DYNAMIC_ARRAY *array, uint array_index) |
void | freeze_size (DYNAMIC_ARRAY *array) |
my_bool | init_dynamic_string (DYNAMIC_STRING *str, const char *init_str, uint init_alloc, uint alloc_increment) |
my_bool | dynstr_append (DYNAMIC_STRING *str, const char *append) |
my_bool | dynstr_append_mem (DYNAMIC_STRING *str, const char *append, uint length) |
my_bool | dynstr_set (DYNAMIC_STRING *str, const char *init_str) |
my_bool | dynstr_realloc (DYNAMIC_STRING *str, ulong additional_size) |
void | dynstr_free (DYNAMIC_STRING *str) |
void | init_alloc_root (MEM_ROOT *mem_root, uint block_size, uint pre_alloc_size) |
gptr | alloc_root (MEM_ROOT *mem_root, unsigned int Size) |
void | free_root (MEM_ROOT *root, myf MyFLAGS) |
void | set_prealloc_root (MEM_ROOT *root, char *ptr) |
void | reset_root_defaults (MEM_ROOT *mem_root, uint block_size, uint prealloc_size) |
char * | strdup_root (MEM_ROOT *root, const char *str) |
char * | strmake_root (MEM_ROOT *root, const char *str, uint len) |
char * | memdup_root (MEM_ROOT *root, const char *str, uint len) |
void | get_defaults_files (int argc, char **argv, char **defaults, char **extra_defaults) |
int | load_defaults (const char *conf_file, const char **groups, int *argc, char ***argv) |
void | free_defaults (char **argv) |
void | print_defaults (const char *conf_file, const char **groups) |
my_bool | my_compress (byte *, ulong *, ulong *) |
my_bool | my_uncompress (byte *, ulong *, ulong *) |
byte * | my_compress_alloc (const byte *packet, ulong *len, ulong *complen) |
ha_checksum | my_checksum (ha_checksum crc, const byte *mem, uint count) |
uint | my_bit_log2 (ulong value) |
uint | my_count_bits (ulonglong v) |
void | my_sleep (ulong m_seconds) |
ulong | crc32 (ulong crc, const uchar *buf, uint len) |
uint | my_set_max_open_files (uint files) |
void | my_free_open_file_info (void) |
ulonglong | my_getsystime (void) |
my_bool | my_gethwaddr (uchar *to) |
uint | get_charset_number (const char *cs_name, uint cs_flags) |
uint | get_collation_number (const char *name) |
const char * | get_charset_name (uint cs_number) |
CHARSET_INFO * | get_charset (uint cs_number, myf flags) |
CHARSET_INFO * | get_charset_by_name (const char *cs_name, myf flags) |
CHARSET_INFO * | get_charset_by_csname (const char *cs_name, uint cs_flags, myf my_flags) |
void | free_charsets (void) |
char * | get_charsets_dir (char *buf) |
my_bool | my_charset_same (CHARSET_INFO *cs1, CHARSET_INFO *cs2) |
my_bool | init_compiled_charsets (myf flags) |
void | add_compiled_collation (CHARSET_INFO *cs) |
ulong | escape_string_for_mysql (CHARSET_INFO *charset_info, char *to, const char *from, ulong length) |
Variables |
C_MODE_START int NEAR | my_errno |
int | errno |
const char **NEAR | my_errmsg [] |
char NEAR | errbuff [NRERRBUFFS][ERRMSGSIZE] |
char * | home_dir |
char * | my_progname |
char NEAR | curr_dir [] |
int(* | error_handler_hook )(uint my_err, const char *str, myf MyFlags) |
int(* | fatal_error_handler_hook )(uint my_err, const char *str, myf MyFlags) |
uint | my_file_limit |
CHARSET_INFO * | default_charset_info |
CHARSET_INFO * | all_charsets [256] |
CHARSET_INFO | compiled_charsets [] |
ulong | my_cache_w_requests |
ulong | my_cache_write |
ulong | my_cache_r_requests |
ulong | my_cache_read |
ulong | my_blocks_used |
ulong | my_blocks_changed |
ulong | my_file_opened |
ulong | my_stream_opened |
ulong | my_tmp_file_created |
uint | mysys_usage_id |
my_bool | my_init_done |
void(* | my_sigtstp_cleanup )(void) |
void(*)(*)(*) | my_abort_hook (int) |
int NEAR | my_umask |
int NEAR NEAR | my_umask_dir |
int NEAR NEAR NEAR | my_recived_signals |
int NEAR NEAR NEAR NEAR | my_safe_to_handle_signal |
int NEAR NEAR NEAR NEAR NEAR | my_dont_interrupt |
my_bool NEAR | mysys_uses_curses |
my_bool NEAR | my_use_symdir |
ulong | sf_malloc_cur_memory |
ulong | sf_malloc_max_memory |
ulong | my_default_record_cache_size |
my_bool NEAR | my_disable_locking |
my_bool NEAR NEAR | my_disable_async_io |
my_bool NEAR NEAR NEAR | my_disable_flush_key_blocks |
my_bool NEAR NEAR NEAR NEAR | my_disable_symlinks |
char | wild_many |
char | wild_one |
char | wild_prefix |
const char * | charsets_dir |
char * | defaults_extra_file |
st_my_file_info * | my_file_info |