diff options
author | unknown <monty@donna.mysql.com> | 2000-09-07 04:55:17 +0300 |
---|---|---|
committer | unknown <monty@donna.mysql.com> | 2000-09-07 04:55:17 +0300 |
commit | bee9933ab83729e6ca2f2826706b1ab5b985df87 (patch) | |
tree | cd775f59b4803ef23e407df9d47af3ae7b517a13 /mysys | |
parent | aaca0e3c6bd71a7b34fcb3a137ab1113a20dca1f (diff) | |
download | mariadb-git-bee9933ab83729e6ca2f2826706b1ab5b985df87.tar.gz |
Small bug fixes
support-files/mysql.server-sys5.sh:
Change mode to -rw-rw-r--
Docs/manual.texi:
Added information about BeOS, Access 2000, AIX and user links
client/mysql.cc:
Fixed SOURCE to work on windows
client/mysqldump.c:
Strip of white space
configure.in:
Fix for AIX
include/dbug.h:
Assert handling
include/my_pthread.h:
Ia64 needs more thread stack than other processors
include/my_sys.h:
More comments
myisam/mi_key.c:
Fixed wrong key length checks
mysql.proj:
update
mysys/charset.c:
Cleanup
mysys/mf_keycache.c:
Moved SEC_LINK to file that used it
mysys/my_static.h:
Moved SEC_LINK to file that used it
scripts/Makefile.am:
Fix for debian
scripts/mysql_install_db.sh:
Cleanup
sql/gen_lex_hash.cc:
Better values
sql/ha_berkeley.cc:
Fix of reading of unique key
sql/handler.cc:
Fix memory allocation bug
sql/mysqld.cc:
Fix for Ia64
sql/share/charsets/latin1.conf:
Fixed sortorder back to scandinavian.
sql/sql_yacc.yy:
FULL shouldn't be a keyword
support-files/Makefile.am:
Fix for debian
support-files/mysql.server.sh:
Cleanups
Diffstat (limited to 'mysys')
-rw-r--r-- | mysys/charset.c | 2 | ||||
-rw-r--r-- | mysys/mf_keycache.c | 14 | ||||
-rw-r--r-- | mysys/my_static.h | 10 |
3 files changed, 13 insertions, 13 deletions
diff --git a/mysys/charset.c b/mysys/charset.c index 384b2c6e71a..54b4dd1a13e 100644 --- a/mysys/charset.c +++ b/mysys/charset.c @@ -380,7 +380,7 @@ CHARSET_INFO *get_charset(uint cs_number, myf flags) (void) init_available_charsets(MYF(0)); /* If it isn't initialized */ cs=get_internal_charset(cs_number); - if (!cs && flags & MY_WME) + if (!cs && (flags & MY_WME)) { char index_file[FN_REFLEN], cs_string[23]; strmov(get_charsets_dir(index_file), "Index"); diff --git a/mysys/mf_keycache.c b/mysys/mf_keycache.c index eca22039444..db23c474564 100644 --- a/mysys/mf_keycache.c +++ b/mysys/mf_keycache.c @@ -42,6 +42,17 @@ #define CHANGED_BLOCKS_MASK (CHANGED_BLOCKS_HASH-1) #define FLUSH_CACHE 2000 /* Sort this many blocks at once */ +typedef struct sec_link { + struct sec_link *next_hash,**prev_hash;/* Blocks linked acc. to hash-value */ + struct sec_link *next_used,*prev_used; + struct sec_link *next_changed,**prev_changed; + File file; + my_off_t diskpos; + byte *buffer; + my_bool changed; +} SEC_LINK; + + static uint find_next_bigger_power(uint value); static SEC_LINK *find_key_block(int file,my_off_t filepos,int *error); @@ -287,7 +298,6 @@ byte *key_cache_read(File file, my_off_t filepos, byte *buff, uint length, } while ((length-= read_length)); pthread_mutex_unlock(&THR_LOCK_keycache); return(start); - pthread_mutex_unlock(&THR_LOCK_keycache); } _my_cache_r_requests++; _my_cache_read++; @@ -457,6 +467,7 @@ static SEC_LINK *find_key_block(int file, my_off_t filepos, int *error) static void free_block(SEC_LINK *used) { used->file= -1; + used->changed=0; if (used != _my_used_first) /* Relink used-chain */ { if (used == _my_used_last) @@ -568,7 +579,6 @@ int flush_key_blocks(File file, enum flush_type type) if (type != FLUSH_KEEP && type != FLUSH_FORCE_WRITE) { /* This will not destroy position or data */ - used->changed=0; _my_blocks_changed--; free_block(used); } diff --git a/mysys/my_static.h b/mysys/my_static.h index dd80a8da1f9..5ab01dec9a9 100644 --- a/mysys/my_static.h +++ b/mysys/my_static.h @@ -33,16 +33,6 @@ struct st_remember { sig_handler (*func)(int number); }; -typedef struct sec_link { - struct sec_link *next_hash,**prev_hash;/* Blocks linked acc. to hash-value */ - struct sec_link *next_used,*prev_used; - struct sec_link *next_changed,**prev_changed; - File file; - my_off_t diskpos; - byte *buffer; - my_bool changed; -} SEC_LINK; - struct irem { struct remember *_pNext; /* Linked list of structures */ struct remember *_pPrev; /* Other link */ |