diff options
Diffstat (limited to 'isam')
-rw-r--r-- | isam/_dynrec.c | 4 | ||||
-rw-r--r-- | isam/_page.c | 4 | ||||
-rw-r--r-- | isam/_search.c | 15 | ||||
-rw-r--r-- | isam/close.c | 6 | ||||
-rw-r--r-- | isam/delete.c | 9 | ||||
-rw-r--r-- | isam/open.c | 2 | ||||
-rw-r--r-- | isam/rkey.c | 4 | ||||
-rw-r--r-- | isam/sort.c | 2 | ||||
-rw-r--r-- | isam/write.c | 14 |
9 files changed, 33 insertions, 27 deletions
diff --git a/isam/_dynrec.c b/isam/_dynrec.c index 25fe01e23f2..c158068eb83 100644 --- a/isam/_dynrec.c +++ b/isam/_dynrec.c @@ -713,8 +713,8 @@ uint _nisam_rec_unpack(register N_INFO *info, register byte *to, byte *from, DBUG_RETURN((info->packed_length=found_length)); err: my_errno=HA_ERR_RECORD_DELETED; - DBUG_PRINT("error",("to_end: %lx -> %lx from_end: %lx -> %lx", - to,to_end,from,from_end)); + DBUG_PRINT("error",("to_end: 0x%lx -> 0x%lx from_end: 0x%lx -> 0x%lx", + (long) to, (long) to_end, (long) from, (long) from_end)); DBUG_DUMP("from",(byte*) info->rec_buff,info->s->base.min_pack_length); DBUG_RETURN(MY_FILE_ERROR); } /* _nisam_rec_unpack */ diff --git a/isam/_page.c b/isam/_page.c index e31115e624f..36626ba186b 100644 --- a/isam/_page.c +++ b/isam/_page.c @@ -70,7 +70,7 @@ int _nisam_write_keypage(register N_INFO *info, register N_KEYDEF *keyinfo, my_errno=EINVAL; return(-1); } - DBUG_PRINT("page",("write page at: %lu",(long) page,buff)); + DBUG_PRINT("page",("write page at: %lu", (long) page)); DBUG_DUMP("buff",(byte*) buff,getint(buff)); #endif @@ -138,6 +138,6 @@ ulong _nisam_new(register N_INFO *info, N_KEYDEF *keyinfo) (uint) keyinfo->base.block_length,0)) pos= NI_POS_ERROR; } - DBUG_PRINT("exit",("Pos: %d",pos)); + DBUG_PRINT("exit",("Pos: %lu", pos)); DBUG_RETURN(pos); } /* _nisam_new */ diff --git a/isam/_search.c b/isam/_search.c index fbffd6786e1..a2a3b096ea1 100644 --- a/isam/_search.c +++ b/isam/_search.c @@ -208,14 +208,15 @@ int _nisam_seq_search(N_INFO *info, register N_KEYDEF *keyinfo, uchar *page, uch if ((flag=_nisam_key_cmp(keyinfo->seg,t_buff,key,key_len,comp_flag)) >= 0) break; #ifdef EXTRA_DEBUG - DBUG_PRINT("loop",("page: %lx key: '%s' flag: %d",page,t_buff,flag)); + DBUG_PRINT("loop",("page: 0x%lx key: '%s' flag: %d", + (long) page, t_buff, flag)); #endif memcpy(buff,t_buff,length); *ret_pos=page; } if (flag == 0) memcpy(buff,t_buff,length); /* Result is first key */ - DBUG_PRINT("exit",("flag: %d ret_pos: %lx",flag,*ret_pos)); + DBUG_PRINT("exit",("flag: %d ret_pos: 0x%lx", flag, (long) *ret_pos)); DBUG_RETURN(flag); } /* _nisam_seq_search */ @@ -754,8 +755,8 @@ int _nisam_search_next(register N_INFO *info, register N_KEYDEF *keyinfo, uint nod_flag; uchar lastkey[N_MAX_KEY_BUFF]; DBUG_ENTER("_nisam_search_next"); - DBUG_PRINT("enter",("nextflag: %d lastpos: %d int_keypos: %lx", - nextflag,info->lastpos,info->int_keypos)); + DBUG_PRINT("enter",("nextflag: %u lastpos: %lu int_keypos: 0x%lx", + nextflag, info->lastpos, (long) info->int_keypos)); DBUG_EXECUTE("key",_nisam_print_key(DBUG_FILE,keyinfo->seg,key);); if ((nextflag & SEARCH_BIGGER && info->int_keypos >= info->int_maxpos) || @@ -807,7 +808,7 @@ int _nisam_search_next(register N_INFO *info, register N_KEYDEF *keyinfo, VOID(_nisam_move_key(keyinfo,info->lastkey,lastkey)); VOID((*keyinfo->get_key)(keyinfo,nod_flag,&info->int_keypos,info->lastkey)); info->lastpos=_nisam_dpos(info,nod_flag,info->int_keypos); - DBUG_PRINT("exit",("found key at %d",info->lastpos)); + DBUG_PRINT("exit",("found key at %lu", info->lastpos)); DBUG_RETURN(0); } /* _nisam_search_next */ @@ -845,7 +846,7 @@ int _nisam_search_first(register N_INFO *info, register N_KEYDEF *keyinfo, regis info->page_changed=info->buff_used=0; info->last_search_keypage=info->int_pos; - DBUG_PRINT("exit",("found key at %d",info->lastpos)); + DBUG_PRINT("exit",("found key at %lu", info->lastpos)); DBUG_RETURN(0); } /* _nisam_search_first */ @@ -884,6 +885,6 @@ int _nisam_search_last(register N_INFO *info, register N_KEYDEF *keyinfo, regist info->page_changed=info->buff_used=0; info->last_search_keypage=info->int_pos; - DBUG_PRINT("exit",("found key at %d",info->lastpos)); + DBUG_PRINT("exit",("found key at %lu", info->lastpos)); DBUG_RETURN(0); } /* _nisam_search_last */ diff --git a/isam/close.c b/isam/close.c index 37425653a5d..59ab91d944e 100644 --- a/isam/close.c +++ b/isam/close.c @@ -23,9 +23,9 @@ int nisam_close(register N_INFO *info) int error=0,flag; ISAM_SHARE *share=info->s; DBUG_ENTER("nisam_close"); - DBUG_PRINT("enter",("base: %lx reopen: %u locks: %u", - info,(uint) share->reopen, - (uint) (share->w_locks+share->r_locks))); + DBUG_PRINT("enter",("base: 0x%lx reopen: %u locks: %u", + (long) info, (uint) share->reopen, + (uint) (share->w_locks + share->r_locks))); pthread_mutex_lock(&THR_LOCK_isam); if (info->lock_type == F_EXTRA_LCK) diff --git a/isam/delete.c b/isam/delete.c index 5aa542561c1..d6dbd19bd53 100644 --- a/isam/delete.c +++ b/isam/delete.c @@ -258,7 +258,8 @@ static int del(register N_INFO *info, register N_KEYDEF *keyinfo, uchar *key, ISAM_SHARE *share=info->s; S_PARAM s_temp; DBUG_ENTER("del"); - DBUG_PRINT("enter",("leaf_page: %ld keypos: %lx",leaf_page,keypos)); + DBUG_PRINT("enter",("leaf_page: %ld keypos: 0x%lx", + (long) leaf_page, (long) keypos)); DBUG_DUMP("leaf_buff",(byte*) leaf_buff,getint(leaf_buff)); endpos=leaf_buff+getint(leaf_buff); @@ -349,7 +350,8 @@ static int underflow(register N_INFO *info, register N_KEYDEF *keyinfo, S_PARAM s_temp; ISAM_SHARE *share=info->s; DBUG_ENTER("underflow"); - DBUG_PRINT("enter",("leaf_page: %ld keypos: %lx",leaf_page,keypos)); + DBUG_PRINT("enter",("leaf_page: %ld keypos: 0x%lx", + leaf_page, (long) keypos)); DBUG_DUMP("anc_buff",(byte*) anc_buff,getint(anc_buff)); DBUG_DUMP("leaf_buff",(byte*) leaf_buff,getint(leaf_buff)); @@ -558,7 +560,8 @@ static uint remove_key(N_KEYDEF *keyinfo, uint nod_flag, int r_length,s_length,first,diff_flag; uchar *start; DBUG_ENTER("remove_key"); - DBUG_PRINT("enter",("keypos: %lx page_end: %lx",keypos,page_end)); + DBUG_PRINT("enter",("keypos: 0x%lx page_end: 0x%lx", + (long) keypos, (long) page_end)); start=keypos; if (!(keyinfo->base.flag & (HA_PACK_KEY | HA_SPACE_PACK_USED))) diff --git a/isam/open.c b/isam/open.c index be62fd86192..39c33c877af 100644 --- a/isam/open.c +++ b/isam/open.c @@ -116,7 +116,7 @@ N_INFO *nisam_open(const char *name, int mode, uint handle_locking) HA_OPTION_TEMP_COMPRESS_RECORD)) { DBUG_PRINT("error",("wrong options: 0x%lx", - uint2korr(share->state.header.options))); + (long) uint2korr(share->state.header.options))); my_errno=HA_ERR_OLD_FILE; goto err; } diff --git a/isam/rkey.c b/isam/rkey.c index bbe4576418b..ee7b9d3ad40 100644 --- a/isam/rkey.c +++ b/isam/rkey.c @@ -27,8 +27,8 @@ int nisam_rkey(N_INFO *info, byte *buf, int inx, const byte *key, uint key_len, uchar *key_buff; ISAM_SHARE *share=info->s; DBUG_ENTER("nisam_rkey"); - DBUG_PRINT("enter",("base: %lx inx: %d search_flag: %d", - info,inx,search_flag)); + DBUG_PRINT("enter",("base: 0x%lx inx: %d search_flag: %d", + (long) info, inx, search_flag)); if ((inx = _nisam_check_index(info,inx)) < 0) DBUG_RETURN(-1); diff --git a/isam/sort.c b/isam/sort.c index 5d13f8085d2..64dcb405157 100644 --- a/isam/sort.c +++ b/isam/sort.c @@ -542,7 +542,7 @@ my_string name; #if O_TEMPORARY == 0 && !defined(CANT_DELETE_OPEN_FILES) VOID(my_delete(name,MYF(MY_WME | ME_NOINPUT))); #endif - DBUG_PRINT("exit",("stream: %lx",stream)); + DBUG_PRINT("exit",("stream: 0x%lx", (long) stream)); DBUG_RETURN (stream); } /* opentemp */ diff --git a/isam/write.c b/isam/write.c index f2c0d8dbc45..2147c7cd59e 100644 --- a/isam/write.c +++ b/isam/write.c @@ -226,7 +226,7 @@ int _nisam_insert(register N_INFO *info, register N_KEYDEF *keyinfo, int key_offset; S_PARAM s_temp; DBUG_ENTER("_nisam_insert"); - DBUG_PRINT("enter",("key_pos: %lx",key_pos)); + DBUG_PRINT("enter",("key_pos: 0x%lx", (long) key_pos)); DBUG_EXECUTE("key",_nisam_print_key(DBUG_FILE,keyinfo->seg,key);); nod_flag=test_if_nod(anc_buff); @@ -243,8 +243,9 @@ int _nisam_insert(register N_INFO *info, register N_KEYDEF *keyinfo, { DBUG_PRINT("test",("t_length: %d ref_len: %d", t_length,s_temp.ref_length)); - DBUG_PRINT("test",("n_ref_len: %d n_length: %d key: %lx", - s_temp.n_ref_length,s_temp.n_length,s_temp.key)); + DBUG_PRINT("test",("n_ref_len: %d n_length: %d key: 0x%lx", + s_temp.n_ref_length, s_temp.n_length, + (long) s_temp.key)); } #endif key_offset = (uint)(endpos-key_pos); @@ -430,7 +431,7 @@ uint _nisam_get_pack_key_length(N_KEYDEF *keyinfo, uint nod_flag, uchar *key_pos if (*start == *key_pos && diff_flag && start != key_end) length++; /* One new pos for ref.len */ - DBUG_PRINT("test",("length: %d key_pos: %lx",length,key_pos)); + DBUG_PRINT("test",("length: %d key_pos: 0x%lx",length,key_pos)); if (n_length != 128) { /* Not same key after */ key=start+ref_length; @@ -597,7 +598,7 @@ _nisam_get_pack_key_length(N_KEYDEF *keyinfo, if (*start == *key_pos && diff_flag && start != key_end) length++; /* One new pos for ref.len */ } - DBUG_PRINT("test",("length: %d key_pos: %lx",length,key_pos)); + DBUG_PRINT("test",("length: %d key_pos: 0x%lx", length, (long) key_pos)); key=start+ref_length; while (n_length > 0 && key < key_end && *key == *key_pos) @@ -696,7 +697,8 @@ uchar *_nisam_find_half_pos(N_INFO *info, N_KEYDEF *keyinfo, uchar *page, uchar VOID((*keyinfo->get_key)(keyinfo,nod_flag,&page,key)); } while (page < end); - DBUG_PRINT("exit",("returns: %lx page: %lx half: %lx",lastpos,page,end)); + DBUG_PRINT("exit",("returns: 0x%lx page: 0x%lx half: 0x%lx", + (long) lastpos, (long) page, (long) end)); DBUG_RETURN(lastpos); } /* _nisam_find_half_pos */ |