summaryrefslogtreecommitdiff
path: root/innobase/dict
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2003-12-20 03:41:04 +0200
committerunknown <monty@mysql.com>2003-12-20 03:41:04 +0200
commit65c44414c21c21ce7b57bd672873558ec2ed3031 (patch)
tree7b73c477120c02f912fc4e2d5105e727385d6bc6 /innobase/dict
parentaa2eb815d6453502889fafb8106bbe33c0632e73 (diff)
downloadmariadb-git-65c44414c21c21ce7b57bd672873558ec2ed3031.tar.gz
Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe
A after merge fix for last merge innobase/btr/btr0btr.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/btr/btr0sea.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/buf/buf0buf.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/buf/buf0flu.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/buf/buf0lru.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/buf/buf0rea.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/com/com0shm.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/data/data0data.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/data/data0type.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/dict/dict0crea.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/dict/dict0dict.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/fil/fil0fil.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/fsp/fsp0fsp.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/fut/fut0lst.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/ha/ha0ha.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/ibuf/ibuf0ibuf.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/include/univ.i: Disabled ut_sprintf/ut_fprintf. Not needed as all number arguments to printf are now casted innobase/lock/lock0lock.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/log/log0log.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/log/log0recv.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/mem/mem0dbg.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/mem/mem0pool.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/mtr/mtr0log.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/mtr/mtr0mtr.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/os/os0file.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/os/os0sync.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/page/page0cur.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/page/page0page.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/read/read0read.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/rem/rem0cmp.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/rem/rem0rec.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/row/row0mysql.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe Heikki, please check the change of % to %% innobase/row/row0sel.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/row/row0undo.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/srv/srv0srv.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/srv/srv0start.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/sync/sync0arr.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/sync/sync0rw.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/sync/sync0sync.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0purge.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0rec.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0roll.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0sys.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0trx.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/trx/trx0undo.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/usr/usr0sess.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/ut/ut0mem.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe innobase/ut/ut0ut.c: Add cast of integer/longlong to (ulong) to make printf/sprintf 64 bit safe sql/sql_delete.cc: After merge fix
Diffstat (limited to 'innobase/dict')
-rw-r--r--innobase/dict/dict0crea.c23
-rw-r--r--innobase/dict/dict0dict.c27
2 files changed, 26 insertions, 24 deletions
diff --git a/innobase/dict/dict0crea.c b/innobase/dict/dict0crea.c
index a5077252c6a..038e4803441 100644
--- a/innobase/dict/dict0crea.c
+++ b/innobase/dict/dict0crea.c
@@ -1177,7 +1177,8 @@ dict_create_or_check_foreign_constraint_tables(void)
error = trx->error_state;
if (error != DB_SUCCESS) {
- fprintf(stderr, "InnoDB: error %lu in creation\n", error);
+ fprintf(stderr, "InnoDB: error %lu in creation\n",
+ (ulong) error);
ut_a(error == DB_OUT_OF_FILE_SPACE);
@@ -1256,27 +1257,27 @@ loop:
/* We allocate the new id from the sequence of table id's */
id = dict_hdr_get_new_id(DICT_HDR_TABLE_ID);
- sprintf(buf2, "%lu_%lu", ut_dulint_get_high(id),
- ut_dulint_get_low(id));
+ sprintf(buf2, "%lu_%lu", (ulong) ut_dulint_get_high(id),
+ (ulong) ut_dulint_get_low(id));
foreign->id = mem_heap_alloc(foreign->heap, ut_strlen(buf2) + 1);
ut_memcpy(foreign->id, buf2, ut_strlen(buf2) + 1);
len += sprintf(buf + len,
"INSERT INTO SYS_FOREIGN VALUES('%lu_%lu', '%s', '%s', %lu);\n",
- ut_dulint_get_high(id),
- ut_dulint_get_low(id),
+ (ulong) ut_dulint_get_high(id),
+ (ulong) ut_dulint_get_low(id),
table->name,
foreign->referenced_table_name,
- foreign->n_fields
- + (foreign->type << 24));
+ (ulong) (foreign->n_fields
+ + (foreign->type << 24)));
for (i = 0; i < foreign->n_fields; i++) {
len += sprintf(buf + len,
"INSERT INTO SYS_FOREIGN_COLS VALUES('%lu_%lu', %lu, '%s', '%s');\n",
- ut_dulint_get_high(id),
- ut_dulint_get_low(id),
- i,
+ (ulong) ut_dulint_get_high(id),
+ (ulong) ut_dulint_get_low(id),
+ (ulong) i,
foreign->foreign_col_names[i],
foreign->referenced_col_names[i]);
}
@@ -1303,7 +1304,7 @@ loop:
if (error != DB_SUCCESS) {
fprintf(stderr,
"InnoDB: Foreign key constraint creation failed:\n"
- "InnoDB: internal error number %lu\n", error);
+ "InnoDB: internal error number %lu\n", (ulong) error);
if (error == DB_DUPLICATE_KEY) {
fprintf(stderr,
diff --git a/innobase/dict/dict0dict.c b/innobase/dict/dict0dict.c
index 0ae36eec6dc..da5ffaecf41 100644
--- a/innobase/dict/dict0dict.c
+++ b/innobase/dict/dict0dict.c
@@ -3804,10 +3804,11 @@ dict_table_print_low(
printf(
"TABLE: name %s, id %lu %lu, columns %lu, indexes %lu, appr.rows %lu\n",
table->name,
- ut_dulint_get_high(table->id),
- ut_dulint_get_low(table->id),
- table->n_cols, UT_LIST_GET_LEN(table->indexes),
- (ulint)table->stat_n_rows);
+ (ulong) ut_dulint_get_high(table->id),
+ (ulong) ut_dulint_get_low(table->id),
+ (ulong) table->n_cols,
+ (ulong) UT_LIST_GET_LEN(table->indexes),
+ (ulong) table->stat_n_rows);
printf(" COLUMNS: ");
for (i = 0; i < table->n_cols - 1; i++) {
@@ -3883,16 +3884,16 @@ dict_index_print_low(
printf(
" INDEX: name %s, table name %s, id %lu %lu, fields %lu/%lu, type %lu\n",
index->name, index->table_name,
- ut_dulint_get_high(tree->id),
- ut_dulint_get_low(tree->id),
- index->n_user_defined_cols,
- index->n_fields, index->type);
+ (ulong) ut_dulint_get_high(tree->id),
+ (ulong) ut_dulint_get_low(tree->id),
+ (ulong) index->n_user_defined_cols,
+ (ulong) index->n_fields, (ulong) index->type);
printf(
" root page %lu, appr.key vals %lu, leaf pages %lu, size pages %lu\n",
- tree->page,
- (ulint)n_vals,
- index->stat_n_leaf_pages,
- index->stat_index_size);
+ (ulong) tree->page,
+ (ulong) n_vals,
+ (ulong) index->stat_n_leaf_pages,
+ (ulong) index->stat_index_size);
printf(" FIELDS: ");
@@ -3920,7 +3921,7 @@ dict_field_print_low(
printf(" %s", field->name);
if (field->prefix_len != 0) {
- printf("(%lu)", field->prefix_len);
+ printf("(%lu)", (ulong) field->prefix_len);
}
}