~mysql/mysql-server/mysql-6.0

« back to all changes in this revision

Viewing changes to mysys/my_static.h

  • Committer: bk at mysql
  • Date: 2000-07-31 19:29:14 UTC
  • Revision ID: sp1r-bk@work.mysql.com-20000731192914-08846
Import changeset

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
 
2
   
 
3
   This library is free software; you can redistribute it and/or
 
4
   modify it under the terms of the GNU Library General Public
 
5
   License as published by the Free Software Foundation; either
 
6
   version 2 of the License, or (at your option) any later version.
 
7
   
 
8
   This library is distributed in the hope that it will be useful,
 
9
   but WITHOUT ANY WARRANTY; without even the implied warranty of
 
10
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
11
   Library General Public License for more details.
 
12
   
 
13
   You should have received a copy of the GNU Library General Public
 
14
   License along with this library; if not, write to the Free
 
15
   Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
 
16
   MA 02111-1307, USA */
 
17
 
 
18
/*
 
19
  Static variables for mysys library. All definied here for easy making of
 
20
  a shared library
 
21
*/
 
22
 
 
23
#include "mysys_priv.h"
 
24
#include <signal.h>
 
25
 
 
26
#define MAX_SIGNALS     10              /* Max signals under a dont-allow */
 
27
#define MIN_KEYBLOCK    (min(IO_SIZE,1024))
 
28
#define MAX_KEYBLOCK    8192            /* Max keyblocklength == 8*IO_SIZE */
 
29
#define MAX_BLOCK_TYPES MAX_KEYBLOCK/MIN_KEYBLOCK
 
30
 
 
31
struct st_remember {
 
32
  int number;
 
33
  sig_handler (*func)(int number);
 
34
};
 
35
 
 
36
typedef struct sec_link {
 
37
  struct sec_link *next_hash,**prev_hash;/* Blocks linked acc. to hash-value */
 
38
  struct sec_link *next_used,*prev_used;
 
39
  struct sec_link *next_changed,**prev_changed;
 
40
  File file;
 
41
  my_off_t diskpos;
 
42
  byte *buffer;
 
43
  my_bool changed;
 
44
} SEC_LINK;
 
45
 
 
46
struct irem {
 
47
    struct remember *_pNext;            /* Linked list of structures       */
 
48
    struct remember *_pPrev;            /* Other link                      */
 
49
    my_string _sFileName;               /* File in which memory was new'ed */
 
50
    uint _uLineNum;                     /* Line number in above file       */
 
51
    uint _uDataSize;                    /* Size requested                  */
 
52
    long _lSpecialValue;                /* Underrun marker value           */
 
53
};
 
54
 
 
55
struct remember {
 
56
    struct irem tInt;
 
57
    char aData[1];
 
58
};
 
59
 
 
60
extern char     NEAR curr_dir[FN_REFLEN],NEAR home_dir_buff[FN_REFLEN];
 
61
 
 
62
extern volatile int _my_signals;
 
63
extern struct st_remember _my_sig_remember[MAX_SIGNALS];
 
64
 
 
65
extern my_bool  key_cache_inited;
 
66
 
 
67
extern const char *soundex_map;
 
68
 
 
69
extern USED_MEM* my_once_root_block;
 
70
extern uint      my_once_extra;
 
71
 
 
72
#ifndef HAVE_TEMPNAM
 
73
extern int      _my_tempnam_used;
 
74
#endif
 
75
 
 
76
extern byte     *sf_min_adress,*sf_max_adress;
 
77
extern uint     cNewCount;
 
78
extern struct remember *pRememberRoot;
 
79
 
 
80
#if defined(THREAD) && !defined(__WIN__)
 
81
extern sigset_t my_signals;             /* signals blocked by mf_brkhant */
 
82
#endif