{
int ret=0;
char buf[160+1],tmp[20];
- unsigned int i,j,rows,trunc;
+ int i,j,rows,trunc;
unsigned char ch;
trunc=0;
if (((i*DUMP_WIDTH)+j)>=len) {
strcat(buf," ");
} else {
- ch=((unsigned char)*((char *)(s)+i*DUMP_WIDTH+j)) & 0xff;
+ ch=((unsigned char)*(s+i*DUMP_WIDTH+j)) & 0xff;
sprintf(tmp,"%02x%c",ch,j==7?'-':' ');
strcat(buf,tmp);
}
for(j=0;j<DUMP_WIDTH;j++) {
if (((i*DUMP_WIDTH)+j)>=len)
break;
- ch=((unsigned char)*((char *)(s)+i*DUMP_WIDTH+j)) & 0xff;
+ ch=((unsigned char)*(s+i*DUMP_WIDTH+j)) & 0xff;
#ifndef CHARSET_EBCDIC
sprintf(tmp,"%c",((ch>=' ')&&(ch<='~'))?ch:'.');
#else