summaryrefslogtreecommitdiff
path: root/myisam
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2003-11-28 12:18:13 +0200
committerunknown <monty@mysql.com>2003-11-28 12:18:13 +0200
commit5a331b9e4e6f46a390b179730bca747a507bd87f (patch)
treee5a58d3f07e9cca109d78031822106ff2be7f6f8 /myisam
parent1362acab293a929fe58ec8591ca4ad51898148f5 (diff)
downloadmariadb-git-5a331b9e4e6f46a390b179730bca747a507bd87f.tar.gz
Added missing SSL library (Should be in source distribution)
Fixed compiler warnings (a lot of hidden variables detected by the Forte compiler) Added a lot of 'version_xxx' strings to 'show variables' Prevent copying of TMP_TABLE_PARAM (This caused core dump bug on Solaris) Fixed problem with printing sub selects to debug log Docs/mysqld_error.txt: Updated error messages Makefile.am: Added missing SSL library (Should be in source distribution) configure.in: Added missing SSL library include/sql_common.h: Move duplicated prototypes innobase/os/os0file.c: Added comment for line that could be removed innobase/srv/srv0srv.c: Added comment for line that could be removed innobase/srv/srv0start.c: Added comment for line that could be removed innobase/trx/trx0sys.c: Added cast to remove compiler warning isam/isamchk.c: Fixed compiler warning libmysql/conf_to_src.c: Include files in proper order myisam/mi_check.c: Removed else part that caused compiler warning myisam/mi_delete.c: Added cast myisam/mi_page.c: Added cast myisam/mi_preload.c: Added cast myisam/mi_write.c: Added cast myisam/myisampack.c: changed 'byte' to 'current_byte' to avoid compiler warnings mysql-test/mysql-test-run.sh: Removed start-from as test '<' is not portable and this can easily be done from command line mysys/hash.c: Added cast mysys/mf_wcomp.c: Removed not reached line mysys/my_append.c: Fixed include file order to get this more portable mysys/my_copy.c: Fixed include file order to get this more portable mysys/my_redel.c: Fixed include file order to get this more portable sql-common/client.c: More DBUG_PRINT sql-common/pack.c: Added casts becasue Fortre compiler apparently compares (ulonglong) < (longlong) as signed sql/ha_heap.cc: Changed variable names to not cause hidden variables sql/ha_innodb.cc: Changed variable names to not cause hidden variables sql/item.cc: Changed variable names to not cause hidden variables sql/item.h: Changed variable names to not cause hidden variables sql/item_cmpfunc.h: Changed variable names to not cause hidden variables sql/item_func.cc: Changed variable names to not cause hidden variables sql/item_subselect.cc: Changed variable names to not cause hidden variables sql/item_subselect.h: Changed variable names to not cause hidden variables sql/item_sum.cc: Changed variable names to not cause hidden variables sql/item_timefunc.cc: Changed variable names to not cause hidden variables sql/log.cc: Changed variable names to not cause hidden variables sql/protocol.cc: Changed variable names to not cause hidden variables sql/protocol.h: Changed variable names to not cause hidden variables Remove function not declared in protocol.cc sql/protocol_cursor.cc: Changed variable names to not cause hidden variables sql/set_var.cc: Added a lot of 'version_xxx' strings Changed 'bdb_version' to 'version_bdb' sql/sql_class.cc: Changed variable names to not cause hidden variables Add TMP_TABLE_PARAM::init() to allow one to initialize structure several times sql/sql_class.h: Prevent copying of TMP_TABLE_PARAM (This caused core dump bug on Solaris) sql/sql_derived.cc: Avoid copying TMP_TABLE_PARAM (Use class version instead) sql/sql_error.cc: More DBUG sql/sql_help.cc: Fixed compiler warning sql/sql_lex.cc: Changed variable names to not cause hidden variables sql/sql_list.h: Changed variable names to not cause hidden variables sql/sql_parse.cc: Changed variable names to not cause hidden variables sql/sql_select.cc: Changed variable names to not cause hidden variables Ensure that you don't send NULL to printf() for %s Fixed problem with printing sub selects to debug log sql/sql_select.h: Changed variable names to not cause hidden variables sql/sql_union.cc: Changed variable names to not cause hidden variables Don't use local copy of TMP_TABLE_PARAM (Caused core dump on Solaris) sql/sql_update.cc: Indentation cleanup sql/sql_yacc.yy: Remove warning strings/conf_to_src.c: Fixed include file order
Diffstat (limited to 'myisam')
-rw-r--r--myisam/mi_check.c38
-rw-r--r--myisam/mi_delete.c2
-rw-r--r--myisam/mi_page.c2
-rw-r--r--myisam/mi_preload.c4
-rw-r--r--myisam/mi_write.c2
-rw-r--r--myisam/myisampack.c14
6 files changed, 30 insertions, 32 deletions
diff --git a/myisam/mi_check.c b/myisam/mi_check.c
index bd8c8c60e33..6f794ad2ea8 100644
--- a/myisam/mi_check.c
+++ b/myisam/mi_check.c
@@ -3301,30 +3301,28 @@ static int sort_ft_key_write(MI_SORT_PARAM *sort_param, const void *a)
ft_buf->buf=0;
return error;
}
- else
- {
- /* flushing buffer */
- if ((error=sort_ft_buf_flush(sort_param)))
- return error;
-word_init_ft_buf:
- a_len+=val_len;
- memcpy(ft_buf->lastkey, a, a_len);
- ft_buf->buf=ft_buf->lastkey+a_len;
- ft_buf->end=ft_buf->lastkey+ (sort_param->keyinfo->block_length-32);
- /* 32 is just a safety margin here
- (at least max(val_len, sizeof(nod_flag)) should be there).
- May be better performance could be achieved if we'd put
- (sort_info->keyinfo->block_length-32)/XXX
- instead.
- TODO: benchmark the best value for XXX.
- */
+ /* flushing buffer */
+ if ((error=sort_ft_buf_flush(sort_param)))
+ return error;
- return 0;
- }
- return -1; /* impossible */
+word_init_ft_buf:
+ a_len+=val_len;
+ memcpy(ft_buf->lastkey, a, a_len);
+ ft_buf->buf=ft_buf->lastkey+a_len;
+ /*
+ 32 is just a safety margin here
+ (at least max(val_len, sizeof(nod_flag)) should be there).
+ May be better performance could be achieved if we'd put
+ (sort_info->keyinfo->block_length-32)/XXX
+ instead.
+ TODO: benchmark the best value for XXX.
+ */
+ ft_buf->end=ft_buf->lastkey+ (sort_param->keyinfo->block_length-32);
+ return 0;
} /* sort_ft_key_write */
+
/* get pointer to record from a key */
static my_off_t get_record_for_key(MI_INFO *info, MI_KEYDEF *keyinfo,
diff --git a/myisam/mi_delete.c b/myisam/mi_delete.c
index f21b0e928b6..a55d5b2a5ca 100644
--- a/myisam/mi_delete.c
+++ b/myisam/mi_delete.c
@@ -241,7 +241,7 @@ static int d_search(register MI_INFO *info, register MI_KEYDEF *keyinfo,
if (info->ft1_to_ft2)
{
/* we're in ft1->ft2 conversion mode. Saving key data */
- insert_dynamic(info->ft1_to_ft2, lastkey+off);
+ insert_dynamic(info->ft1_to_ft2, (char*) (lastkey+off));
}
else
{
diff --git a/myisam/mi_page.c b/myisam/mi_page.c
index 8c6981afa00..c70209c2da6 100644
--- a/myisam/mi_page.c
+++ b/myisam/mi_page.c
@@ -52,7 +52,7 @@ uchar *_mi_fetch_keypage(register MI_INFO *info, MI_KEYDEF *keyinfo,
{
DBUG_PRINT("error",("page %lu had wrong page length: %u",
(ulong) page, page_size));
- DBUG_DUMP("page", tmp, keyinfo->block_length);
+ DBUG_DUMP("page", (char*) tmp, keyinfo->block_length);
info->last_keypage = HA_OFFSET_ERROR;
my_errno = HA_ERR_CRASHED;
tmp = 0;
diff --git a/myisam/mi_preload.c b/myisam/mi_preload.c
index 80489cbcd13..5e03d489efe 100644
--- a/myisam/mi_preload.c
+++ b/myisam/mi_preload.c
@@ -108,11 +108,11 @@ int mi_preload(MI_INFO *info, ulonglong key_map, my_bool ignore_leaves)
}
while (pos != key_file_length);
- my_free(buff, MYF(0));
+ my_free((char*) buff, MYF(0));
DBUG_RETURN(0);
err:
- my_free(buff, MYF(MY_ALLOW_ZERO_PTR));
+ my_free((char*) buff, MYF(MY_ALLOW_ZERO_PTR));
DBUG_RETURN(my_errno= errno);
}
diff --git a/myisam/mi_write.c b/myisam/mi_write.c
index 86c45e0692f..d13ba6c2c4e 100644
--- a/myisam/mi_write.c
+++ b/myisam/mi_write.c
@@ -521,7 +521,7 @@ int _mi_insert(register MI_INFO *info, register MI_KEYDEF *keyinfo,
we cannot easily dispatch an empty page here */
b+=blen+ft2len+2;
for (a=anc_buff+a_length ; b < a ; b+=ft2len+2)
- insert_dynamic(info->ft1_to_ft2, b);
+ insert_dynamic(info->ft1_to_ft2, (char*) b);
/* fixing the page's length - it contains only one key now */
mi_putint(anc_buff,2+blen+ft2len+2,0);
diff --git a/myisam/myisampack.c b/myisam/myisampack.c
index 5ca57248204..93edde33bdb 100644
--- a/myisam/myisampack.c
+++ b/myisam/myisampack.c
@@ -51,7 +51,7 @@ struct st_file_buffer {
char *buffer,*pos,*end;
my_off_t pos_in_file;
int bits;
- uint byte;
+ uint current_byte;
};
struct st_huff_tree;
@@ -1912,7 +1912,7 @@ static void init_file_buffer(File file, pbool read_buffer)
file_buffer.pos=file_buffer.buffer;
file_buffer.bits=BITS_SAVED;
}
- file_buffer.byte=0;
+ file_buffer.current_byte=0;
}
@@ -1961,13 +1961,13 @@ static void write_bits (register ulong value, register uint bits)
{
if ((file_buffer.bits-=(int) bits) >= 0)
{
- file_buffer.byte|=value << file_buffer.bits;
+ file_buffer.current_byte|=value << file_buffer.bits;
}
else
{
reg3 uint byte_buff;
bits= (uint) -file_buffer.bits;
- byte_buff=file_buffer.byte | (uint) (value >> bits);
+ byte_buff=file_buffer.current_byte | (uint) (value >> bits);
#if BITS_SAVED == 32
*file_buffer.pos++= (byte) (byte_buff >> 24) ;
*file_buffer.pos++= (byte) (byte_buff >> 16) ;
@@ -1993,7 +1993,7 @@ static void write_bits (register ulong value, register uint bits)
if (file_buffer.pos >= file_buffer.end)
VOID(flush_buffer((uint) ~0));
file_buffer.bits=(int) (BITS_SAVED - bits);
- file_buffer.byte=(uint) (value << (BITS_SAVED - bits));
+ file_buffer.current_byte=(uint) (value << (BITS_SAVED - bits));
}
return;
}
@@ -2005,7 +2005,7 @@ static void flush_bits (void)
uint bits,byte_buff;
bits=(file_buffer.bits) & ~7;
- byte_buff = file_buffer.byte >> bits;
+ byte_buff = file_buffer.current_byte >> bits;
bits=BITS_SAVED - bits;
while (bits > 0)
{
@@ -2013,7 +2013,7 @@ static void flush_bits (void)
*file_buffer.pos++= (byte) (uchar) (byte_buff >> bits) ;
}
file_buffer.bits=BITS_SAVED;
- file_buffer.byte=0;
+ file_buffer.current_byte=0;
return;
}