1
/* Copyright (C) 2000 MySQL AB
3
This program is free software; you can redistribute it and/or modify
4
it under the terms of the GNU General Public License as published by
5
the Free Software Foundation; version 2 of the License.
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
GNU General Public License for more details.
12
You should have received a copy of the GNU General Public License
13
along with this program; if not, write to the Free Software
14
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
17
Static variables for mysys library. All definied here for easy making of
21
#include "mysys_priv.h"
22
#include "my_static.h"
25
my_bool timed_mutexes= 0;
29
const char *my_progname=0;
30
char curr_dir[FN_REFLEN]= {0},
31
home_dir_buff[FN_REFLEN]= {0};
32
ulong my_stream_opened=0,my_file_opened=0, my_tmp_file_created=0;
33
ulong my_file_total_opened= 0;
34
int my_umask=0664, my_umask_dir=0777;
38
struct st_my_file_info my_file_info_default[MY_NFILE]= {{0,UNOPEN}};
39
uint my_file_limit= MY_NFILE;
40
struct st_my_file_info *my_file_info= my_file_info_default;
43
int my_dont_interrupt=0;
44
volatile int _my_signals=0;
45
struct st_remember _my_sig_remember[MAX_SIGNALS]={{0,0}};
47
sigset_t my_signals; /* signals blocked by mf_brkhant */
50
/* from mf_reccache.c */
51
ulong my_default_record_cache_size=RECORD_CACHE_SIZE;
54
/* ABCDEFGHIJKLMNOPQRSTUVWXYZ */
55
/* :::::::::::::::::::::::::: */
56
const char *soundex_map= "01230120022455012623010202";
59
USED_MEM* my_once_root_block=0; /* pointer to first block */
60
uint my_once_extra=ONCE_ALLOC_INIT; /* Memory to alloc / block */
62
/* from my_largepage.c */
63
#ifdef HAVE_LARGE_PAGES
64
my_bool my_use_large_pages= 0;
65
uint my_large_page_size= 0;
68
/* from safe_malloc */
69
uint sf_malloc_prehunc=0, /* If you have problem with core- */
70
sf_malloc_endhunc=0, /* dump when malloc-message.... */
71
/* set theese to 64 or 128 */
72
sf_malloc_quick=0; /* set if no calls to sanity */
73
ulong sf_malloc_cur_memory= 0L; /* Current memory usage */
74
ulong sf_malloc_max_memory= 0L; /* Maximum memory usage */
75
uint sf_malloc_count= 0; /* Number of times NEW() was called */
76
uchar *sf_min_adress= (uchar*) ~(unsigned long) 0L,
77
*sf_max_adress= (uchar*) 0L;
78
/* Root of the linked list of struct st_irem */
79
struct st_irem *sf_malloc_root = NULL;
82
int volatile my_have_got_alarm=0; /* declare variable to reset */
83
ulong my_time_to_wait_for_lock=2; /* In seconds */
87
char * globerrs[GLOBERRS]; /* my_error_messages is here */
89
void (*my_abort_hook)(int) = (void(*)(int)) exit;
90
void (*error_handler_hook)(uint error,const char *str,myf MyFlags)=
92
void (*fatal_error_handler_hook)(uint error,const char *str,myf MyFlags)=
95
/* How to disable options */
96
my_bool my_disable_locking=0;
97
my_bool my_disable_async_io=0;
98
my_bool my_disable_flush_key_blocks=0;
99
my_bool my_disable_symlinks=0;
100
my_bool mysys_uses_curses=0;