fixed the other QUICKMATCH errors i was getting
Current lines and files i get errors on:
hashstr.c: In function 'void hash_dump(int)':
hashstr.c:180: error: cast from 'hashstr_data*' to 'int' loses precision
hashstr.c: In function 'void show_high_hash(int)':
hashstr.c:248: error: cast from 'hashstr_data*' to 'int' loses precision
165:void hash_dump( int hash )
166:{
167: struct hashstr_data *ptr;
168: char *str;
169: int c, psize;
171: if ( hash > STR_HASH_SIZE || hash < 0 )
172: {
173: fprintf( stderr, "hash_dump: invalid hash size\n\r" );
174: return;
175: }
176: psize = sizeof(struct hashstr_data);
178: for ( c=0, ptr = string_hash[hash]; ptr; ptr = ptr->next, c++ )
179: {
180: str = (char *) (((int) ptr) + psize);
181: fprintf( stderr, "Len:%4d Lnks:%5d Str: %s\n\r",
182: ptr->length, ptr->links, str );
183: }
184: fprintf( stderr, "Total strings in hash %d: %d\n\r", hash, c );
185:}
reset.c: In function 'void do_reset(CHAR_DATA*, char*)':
reset.c:996: error: cast from 'char*' to 'int' loses precision
reset.c: In function 'void do_rreset(CHAR_DATA*, char*)':
reset.c:1052: error: cast from 'char*' to 'int' loses precision
reset.c: In function 'void reset_area(AREA_DATA*)':
reset.c:1290: error: cast from 'char*' to 'int' loses precision
line 996 offending chunk of code:
{
AREA_DATA *tmp;
985: for ( tmp = first_build; tmp; tmp = tmp->next )
986: if ( tmp == pArea )
987: break;
988: if ( !tmp )
989: for ( tmp = first_area; tmp; tmp = tmp->next )
990: if ( tmp == pArea )
991: break;
992: if ( !tmp )
993: {
994: send_to_char("Your area pointer got lost. Reset mode off.\n\r", ch);
995: bug("do_reset: %s's dest_buf points to invalid area",
996: (int)ch->name);
997: ch->substate = SUB_NONE;
998: DISPOSE(ch->dest_buf);
999: return;
1000: }
|