summaryrefslogtreecommitdiff
path: root/innobase
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2003-11-23 14:36:41 +0200
committerunknown <monty@mysql.com>2003-11-23 14:36:41 +0200
commitce44db9fb1fc20133e05cab5cd99195c814f3b05 (patch)
treedf2c427c1d086dc0727fa8656815cece6df4aeb2 /innobase
parentb1a563c39233b6af3939f23e4b50d89d7b28a74a (diff)
downloadmariadb-git-ce44db9fb1fc20133e05cab5cd99195c814f3b05.tar.gz
Fixed compiler warnings from Intel compiler in Win64
Added option --max-record-length=# to myisamchk Don't try repair twice if doing myisamchk --repair --force Shared memory handler didn't clean up things on errors or shutdown VC++Files/libmysqltest/mytest.c: Fixed compiler warnings from Intel compiler include/myisam.h: Added option --max-record-length=# to myisamchk include/mysql_com.h: Fixed compiler warnings from Intel compiler innobase/btr/btr0btr.c: Fixed compiler warnings from Intel compiler innobase/btr/btr0cur.c: Fixed compiler warnings from Intel compiler innobase/include/btr0btr.ic: Fixed compiler warnings from Intel compiler innobase/include/buf0buf.ic: Fixed compiler warnings from Intel compiler innobase/include/row0sel.ic: Fixed compiler warnings from Intel compiler innobase/include/row0upd.ic: Fixed compiler warnings from Intel compiler innobase/include/trx0rseg.ic: Fixed compiler warnings from Intel compiler innobase/pars/pars0opt.c: Fixed compiler warnings from Intel compiler innobase/que/que0que.c: Fixed compiler warnings from Intel compiler myisam/mi_check.c: Added option --max-record-length=# to myisamchk Better error messages myisam/myisamchk.c: Added option --max-record-length=# to myisamchk Don't try repair twice if doing myisamchk --repair --force mysql-test/r/create.result: Updated test results mysql-test/t/create.test: Better initialization sql/ha_innodb.cc: Fixed compiler warnings from Intel compiler sql/item_func.cc: Fixed compiler warnings from Intel compiler sql/mysqld.cc: Fixed compiler warnings from Intel compiler Cleaned up handle_connections_shared_memory Shared memory handler didn't clean up things on errors or shutdown strings/bmove512.c: Fixed compiler warnings from Intel compiler
Diffstat (limited to 'innobase')
-rw-r--r--innobase/btr/btr0btr.c34
-rw-r--r--innobase/btr/btr0cur.c27
-rw-r--r--innobase/include/btr0btr.ic2
-rw-r--r--innobase/include/buf0buf.ic8
-rw-r--r--innobase/include/row0sel.ic2
-rw-r--r--innobase/include/row0upd.ic4
-rw-r--r--innobase/include/trx0rseg.ic4
-rw-r--r--innobase/pars/pars0opt.c5
-rw-r--r--innobase/que/que0que.c13
9 files changed, 55 insertions, 44 deletions
diff --git a/innobase/btr/btr0btr.c b/innobase/btr/btr0btr.c
index 3d11cbe1748..686c35d1300 100644
--- a/innobase/btr/btr0btr.c
+++ b/innobase/btr/btr0btr.c
@@ -600,8 +600,8 @@ btr_page_get_father_for_rec(
"InnoDB: father ptr page no %lu, child page no %lu\n",
(UT_LIST_GET_FIRST(tree->tree_indexes))->table_name,
(UT_LIST_GET_FIRST(tree->tree_indexes))->name,
- btr_node_ptr_get_child_page_no(node_ptr),
- buf_frame_get_page_no(page));
+ (unsigned long) btr_node_ptr_get_child_page_no(node_ptr),
+ (unsigned long) buf_frame_get_page_no(page));
page_rec_print(page_rec_get_next(page_get_infimum_rec(page)));
page_rec_print(node_ptr);
@@ -877,7 +877,9 @@ btr_page_reorganize_low(
"InnoDB: Error: page old data size %lu new data size %lu\n"
"InnoDB: Error: page old max ins size %lu new max ins size %lu\n"
"InnoDB: Make a detailed bug report and send it to mysql@lists.mysql.com\n",
- data_size1, data_size2, max_ins_size1, max_ins_size2);
+ (unsigned long) data_size1, (unsigned long) data_size2,
+ (unsigned long) max_ins_size1,
+ (unsigned long) max_ins_size2);
}
buf_frame_free(new_page);
@@ -2356,8 +2358,10 @@ btr_index_rec_validate(
"InnoDB: Record in index %s in table %s, page %lu, at offset %lu\n"
"InnoDB: has %lu fields, should have %lu\n",
index->name, index->table_name,
- buf_frame_get_page_no(page), (ulint)(rec - page),
- rec_get_n_fields(rec), n);
+ (unsigned long) buf_frame_get_page_no(page),
+ (unsigned long) (rec - page),
+ (unsigned long) rec_get_n_fields(rec),
+ (unsigned long) n);
if (!dump_on_error) {
@@ -2390,9 +2394,11 @@ btr_index_rec_validate(
"InnoDB: Record in index %s in table %s, page %lu, at offset %lu\n"
"InnoDB: field %lu len is %lu, should be %lu\n",
index->name, index->table_name,
- buf_frame_get_page_no(page),
- (ulint)(rec - page),
- i, len, dtype_get_fixed_size(type));
+ (unsigned long) buf_frame_get_page_no(page),
+ (unsigned long) (rec - page),
+ (unsigned long) i,
+ (unsigned long) len,
+ (unsigned long) dtype_get_fixed_size(type));
if (!dump_on_error) {
@@ -2541,7 +2547,7 @@ loop:
fprintf(stderr,
"InnoDB: Error on pages %lu and %lu in index %s table %s\n",
buf_frame_get_page_no(page),
- right_page_no,
+ (unsigned long) right_page_no,
index->name, index->table_name);
fprintf(stderr,
@@ -2581,7 +2587,7 @@ loop:
&mtr)) {
fprintf(stderr,
"InnoDB: Error on page %lu in index %s table %s\n",
- buf_frame_get_page_no(page),
+ (unsigned long) buf_frame_get_page_no(page),
index->name, index->table_name);
fprintf(stderr,
@@ -2596,7 +2602,7 @@ loop:
fprintf(stderr,
"InnoDB: node ptr child page n:o %lu\n",
- btr_node_ptr_get_child_page_no(node_ptr));
+ (unsigned long) btr_node_ptr_get_child_page_no(node_ptr));
rec_sprintf(err_buf, 900,
btr_page_get_father_for_rec(tree, page,
@@ -2679,7 +2685,7 @@ loop:
fprintf(stderr,
"InnoDB: Error on page %lu in index %s table %s\n",
- buf_frame_get_page_no(page),
+ (unsigned long) buf_frame_get_page_no(page),
index->name, index->table_name);
buf_page_print(father_page);
@@ -2699,7 +2705,7 @@ loop:
fprintf(stderr,
"InnoDB: Error on page %lu in index %s table %s\n",
- buf_frame_get_page_no(page),
+ (unsigned long) buf_frame_get_page_no(page),
index->name, index->table_name);
buf_page_print(father_page);
@@ -2717,7 +2723,7 @@ loop:
fprintf(stderr,
"InnoDB: Error on page %lu in index %s table %s\n",
- buf_frame_get_page_no(page),
+ (unsigned long) buf_frame_get_page_no(page),
index->name, index->table_name);
buf_page_print(father_page);
diff --git a/innobase/btr/btr0cur.c b/innobase/btr/btr0cur.c
index 5743ba54544..93e9e815c99 100644
--- a/innobase/btr/btr0cur.c
+++ b/innobase/btr/btr0cur.c
@@ -874,8 +874,8 @@ btr_cur_optimistic_insert(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to insert to table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
index->table_name, index->name);
dtuple_print(entry);
}
@@ -978,7 +978,8 @@ calculate_sizes_again:
fprintf(stderr,
"InnoDB: Error: cannot insert tuple %s to index %s of table %s\n"
"InnoDB: max insert size %lu\n",
- err_buf, index->name, index->table->name, max_size);
+ err_buf, index->name, index->table->name,
+ (unsigned long) max_size);
mem_free(err_buf);
}
@@ -1343,8 +1344,8 @@ btr_cur_update_sec_rec_in_place(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to update table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
index->table_name, index->name);
rec_print(rec);
}
@@ -1407,8 +1408,8 @@ btr_cur_update_in_place(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to update table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
index->table_name, index->name);
rec_print(rec);
}
@@ -1509,8 +1510,8 @@ btr_cur_optimistic_update(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to update table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
index->table_name, index->name);
rec_print(rec);
}
@@ -2059,8 +2060,8 @@ btr_cur_del_mark_set_clust_rec(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to del mark table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
index->table_name, index->name);
rec_print(rec);
}
@@ -2199,8 +2200,8 @@ btr_cur_del_mark_set_sec_rec(
if (btr_cur_print_record_ops && thr) {
printf(
"Trx with id %lu %lu going to del mark table %s index %s\n",
- ut_dulint_get_high(thr_get_trx(thr)->id),
- ut_dulint_get_low(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_high(thr_get_trx(thr)->id),
+ (unsigned long) ut_dulint_get_low(thr_get_trx(thr)->id),
cursor->index->table_name, cursor->index->name);
rec_print(rec);
}
diff --git a/innobase/include/btr0btr.ic b/innobase/include/btr0btr.ic
index 16057d2c8a6..301a73b3444 100644
--- a/innobase/include/btr0btr.ic
+++ b/innobase/include/btr0btr.ic
@@ -203,7 +203,7 @@ btr_node_ptr_get_child_page_no(
if (page_no == 0) {
fprintf(stderr,
"InnoDB: a nonsensical page number 0 in a node ptr record at offset %lu\n",
- (ulint)(rec - buf_frame_align(rec)));
+ (unsigned long)(rec - buf_frame_align(rec)));
buf_page_print(buf_frame_align(rec));
}
diff --git a/innobase/include/buf0buf.ic b/innobase/include/buf0buf.ic
index 281bb1ea527..eb22bae7ff0 100644
--- a/innobase/include/buf0buf.ic
+++ b/innobase/include/buf0buf.ic
@@ -219,8 +219,8 @@ buf_block_align(
"InnoDB: corruption. If this happens in an InnoDB database recovery,\n"
"InnoDB: you can look from section 6.1 at http://www.innodb.com/ibman.html\n"
"InnoDB: how to force recovery.\n",
- (ulint)ptr, (ulint)frame_zero,
- (ulint)(buf_pool->high_end));
+ (long)ptr, (long)frame_zero,
+ (long)(buf_pool->high_end));
ut_a(0);
}
@@ -255,8 +255,8 @@ buf_frame_align(
"InnoDB: corruption. If this happens in an InnoDB database recovery,\n"
"InnoDB: you can look from section 6.1 at http://www.innodb.com/ibman.html\n"
"InnoDB: how to force recovery.\n",
- (ulint)ptr, (ulint)(buf_pool->frame_zero),
- (ulint)(buf_pool->high_end));
+ (long)ptr, (long)(buf_pool->frame_zero),
+ (long)(buf_pool->high_end));
ut_a(0);
}
diff --git a/innobase/include/row0sel.ic b/innobase/include/row0sel.ic
index 9005624b6ca..994638790c0 100644
--- a/innobase/include/row0sel.ic
+++ b/innobase/include/row0sel.ic
@@ -77,7 +77,7 @@ open_step(
if (err != DB_SUCCESS) {
/* SQL error detected */
- printf("SQL error %lu\n", err);
+ printf("SQL error %lu\n", (unsigned long) err);
ut_error;
que_thr_handle_error(thr, err, NULL, 0);
diff --git a/innobase/include/row0upd.ic b/innobase/include/row0upd.ic
index 7015b2eda13..1878431d1a4 100644
--- a/innobase/include/row0upd.ic
+++ b/innobase/include/row0upd.ic
@@ -86,8 +86,8 @@ upd_field_set_field_no(
fprintf(stderr,
"InnoDB: Error: trying to access field %lu in table %s\n"
"InnoDB: index %s, but index has only %lu fields\n",
- field_no, index->table_name, index->name,
- dict_index_get_n_fields(index));
+ (unsigned long) field_no, index->table_name, index->name,
+ (unsigned long) dict_index_get_n_fields(index));
}
dtype_copy(dfield_get_type(&(upd_field->new_val)),
diff --git a/innobase/include/trx0rseg.ic b/innobase/include/trx0rseg.ic
index 423447d5566..6b242b66c09 100644
--- a/innobase/include/trx0rseg.ic
+++ b/innobase/include/trx0rseg.ic
@@ -63,7 +63,7 @@ trx_rsegf_get_nth_undo(
{
if (n >= TRX_RSEG_N_SLOTS) {
fprintf(stderr,
- "InnoDB: Error: trying to get slot %lu of rseg\n", n);
+ "InnoDB: Error: trying to get slot %lu of rseg\n", (unsigned long) n);
ut_a(0);
}
@@ -84,7 +84,7 @@ trx_rsegf_set_nth_undo(
{
if (n >= TRX_RSEG_N_SLOTS) {
fprintf(stderr,
- "InnoDB: Error: trying to set slot %lu of rseg\n", n);
+ "InnoDB: Error: trying to set slot %lu of rseg\n", (unsigned long) n);
ut_a(0);
}
diff --git a/innobase/pars/pars0opt.c b/innobase/pars/pars0opt.c
index 4faf83b47a3..9b0495a01cd 100644
--- a/innobase/pars/pars0opt.c
+++ b/innobase/pars/pars0opt.c
@@ -1235,7 +1235,8 @@ opt_print_query_plan(
printf(
"Table %s index %s; exact m. %lu, match %lu, end conds %lu\n",
plan->table->name, plan->index->name,
- plan->n_exact_match, n_fields,
- UT_LIST_GET_LEN(plan->end_conds));
+ (unsigned long) plan->n_exact_match,
+ (unsigned long) n_fields,
+ (unsigned long) UT_LIST_GET_LEN(plan->end_conds));
}
}
diff --git a/innobase/que/que0que.c b/innobase/que/que0que.c
index 3f28a4b40a5..7e4babd43ef 100644
--- a/innobase/que/que0que.c
+++ b/innobase/que/que0que.c
@@ -513,7 +513,7 @@ que_graph_free_recursive(
if (thr->magic_n != QUE_THR_MAGIC_N) {
fprintf(stderr,
"que_thr struct appears corrupt; magic n %lu\n",
- thr->magic_n);
+ (unsigned long) thr->magic_n);
mem_analyze_corruption((byte*)thr);
ut_a(0);
}
@@ -625,7 +625,7 @@ que_graph_free_recursive(
default:
fprintf(stderr,
"que_node struct appears corrupt; type %lu\n",
- que_node_get_type(node));
+ (unsigned long) que_node_get_type(node));
mem_analyze_corruption((byte*)node);
ut_a(0);
}
@@ -1105,7 +1105,8 @@ que_thr_move_to_run_state_for_mysql(
{
if (thr->magic_n != QUE_THR_MAGIC_N) {
fprintf(stderr,
- "que_thr struct appears corrupt; magic n %lu\n", thr->magic_n);
+ "que_thr struct appears corrupt; magic n %lu\n",
+ (unsigned long) thr->magic_n);
mem_analyze_corruption((byte*)thr);
@@ -1141,7 +1142,8 @@ que_thr_stop_for_mysql_no_error(
if (thr->magic_n != QUE_THR_MAGIC_N) {
fprintf(stderr,
- "que_thr struct appears corrupt; magic n %lu\n", thr->magic_n);
+ "que_thr struct appears corrupt; magic n %lu\n",
+ (unsigned long) thr->magic_n);
mem_analyze_corruption((byte*)thr);
@@ -1216,7 +1218,8 @@ que_node_print_info(
str = (char *) "UNKNOWN NODE TYPE";
}
- printf("Node type %lu: %s, address %lx\n", type, str, addr);
+ printf("Node type %lu: %s, address %lx\n", (unsigned long) type, str,
+ (unsigned long) addr);
}
/**************************************************************************