Commit 22e74da9 authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

winedump: Remove useless casts to self.

parent fbc92ec2
...@@ -413,7 +413,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len) ...@@ -413,7 +413,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
if (memcmp(signature, "NB10", 4) == 0) if (memcmp(signature, "NB10", 4) == 0)
{ {
const CODEVIEW_PDB_DATA* pdb_data; const CODEVIEW_PDB_DATA* pdb_data;
pdb_data = (const void *)cv_base; pdb_data = cv_base;
printf(" Filepos: 0x%08lX\n", pdb_data->filepos); printf(" Filepos: 0x%08lX\n", pdb_data->filepos);
printf(" TimeStamp: %08X (%s)\n", printf(" TimeStamp: %08X (%s)\n",
...@@ -426,7 +426,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len) ...@@ -426,7 +426,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
{ {
const OMFSignatureRSDS* rsds_data; const OMFSignatureRSDS* rsds_data;
rsds_data = (const void *)cv_base; rsds_data = cv_base;
printf(" Guid: %s\n", get_guid_str(&rsds_data->guid)); printf(" Guid: %s\n", get_guid_str(&rsds_data->guid));
printf(" Age: %08X\n", rsds_data->age); printf(" Age: %08X\n", rsds_data->age);
printf(" Filename: %s\n", rsds_data->name); printf(" Filename: %s\n", rsds_data->name);
......
...@@ -91,7 +91,7 @@ static int full_numeric_leaf(struct full_value* fv, const unsigned short int* le ...@@ -91,7 +91,7 @@ static int full_numeric_leaf(struct full_value* fv, const unsigned short int* le
case LF_USHORT: case LF_USHORT:
length += 2; length += 2;
fv->v.i = *(const unsigned short*)leaf; fv->v.i = *leaf;
break; break;
case LF_LONG: case LF_LONG:
...@@ -1490,7 +1490,7 @@ void codeview_dump_linetab2(const char* linetab, DWORD size, const char* strimag ...@@ -1490,7 +1490,7 @@ void codeview_dump_linetab2(const char* linetab, DWORD size, const char* strimag
break; break;
default: default:
printf("%sblock end %x\n", pfx, lt2->header); printf("%sblock end %x\n", pfx, lt2->header);
lt2 = (const struct codeview_linetab2*)((const char*)linetab + size); lt2 = (const struct codeview_linetab2*)(linetab + size);
continue; continue;
} }
lt2 = codeview_linetab2_next_block(lt2); lt2 = codeview_linetab2_next_block(lt2);
......
...@@ -590,7 +590,7 @@ static char *demangle_datatype (char **str, compound_type *ct, ...@@ -590,7 +590,7 @@ static char *demangle_datatype (char **str, compound_type *ct,
if (!ct->expression) if (!ct->expression)
return NULL; return NULL;
return (char *)(*str = iter); return *str = iter;
} }
...@@ -629,7 +629,7 @@ static char *get_constraints_convention_1 (char **str, compound_type *ct) ...@@ -629,7 +629,7 @@ static char *get_constraints_convention_1 (char **str, compound_type *ct)
char *iter = *str, **retval = str; char *iter = *str, **retval = str;
if (ct->have_qualifiers) if (ct->have_qualifiers)
return (char *)*str; /* Previously got constraints for this type */ return *str; /* Previously got constraints for this type */
if (*iter == '?' || *iter == 'A') if (*iter == '?' || *iter == 'A')
{ {
...@@ -651,7 +651,7 @@ static char *get_constraints_convention_1 (char **str, compound_type *ct) ...@@ -651,7 +651,7 @@ static char *get_constraints_convention_1 (char **str, compound_type *ct)
} }
} }
return (char *)(*retval = iter); return *retval = iter;
} }
...@@ -666,7 +666,7 @@ static char *get_constraints_convention_2 (char **str, compound_type *ct) ...@@ -666,7 +666,7 @@ static char *get_constraints_convention_2 (char **str, compound_type *ct)
/* FIXME: Why do arrays have both convention 1 & 2 constraints? */ /* FIXME: Why do arrays have both convention 1 & 2 constraints? */
if (ct->have_qualifiers && ct->dest_type != 'Q') if (ct->have_qualifiers && ct->dest_type != 'Q')
return (char *)*str; /* Previously got constraints for this type */ return *str; /* Previously got constraints for this type */
ct->have_qualifiers = TRUE; /* Even if none, we've got all we're getting */ ct->have_qualifiers = TRUE; /* Even if none, we've got all we're getting */
...@@ -687,7 +687,7 @@ static char *get_constraints_convention_2 (char **str, compound_type *ct) ...@@ -687,7 +687,7 @@ static char *get_constraints_convention_2 (char **str, compound_type *ct)
break; break;
} }
return (char *)(*retval = iter); return *retval = iter;
} }
......
...@@ -336,7 +336,7 @@ static void pdb_dump_symbols(struct pdb_reader* reader, PDB_STREAM_INDEXES* sidx ...@@ -336,7 +336,7 @@ static void pdb_dump_symbols(struct pdb_reader* reader, PDB_STREAM_INDEXES* sidx
for (j = cfile; j < src->nSrcFiles && j < cfile + indx[i]; j++) for (j = cfile; j < src->nSrcFiles && j < cfile + indx[i]; j++)
{ {
/* FIXME: in some cases, it's a p_string but WHEN ? */ /* FIXME: in some cases, it's a p_string but WHEN ? */
if (cstr + offset[j] >= (const char*)start_cstr /* wrap around */ && if (cstr + offset[j] >= start_cstr /* wrap around */ &&
cstr + offset[j] < (const char*)src + symbols->srcmodule_size) cstr + offset[j] < (const char*)src + symbols->srcmodule_size)
printf("\t\t\tSource file: %s\n", cstr + offset[j]); printf("\t\t\tSource file: %s\n", cstr + offset[j]);
else else
...@@ -367,7 +367,7 @@ static void pdb_dump_symbols(struct pdb_reader* reader, PDB_STREAM_INDEXES* sidx ...@@ -367,7 +367,7 @@ static void pdb_dump_symbols(struct pdb_reader* reader, PDB_STREAM_INDEXES* sidx
"\t\tAge: %08u\n" "\t\tAge: %08u\n"
"\t\tfile1: %s\n" "\t\tfile1: %s\n"
"\t\tfile2: %s\n", "\t\tfile2: %s\n",
(ULONG_PTR)((const char*)imp - (const char*)first), (ULONG_PTR)((const char*)imp - first),
imp->unknown1, imp->unknown1,
imp->unknown2, imp->unknown2,
imp->TimeDateStamp, imp->TimeDateStamp,
......
...@@ -311,7 +311,7 @@ static const char *get_type (parsed_symbol *sym, const char *proto, int arg) ...@@ -311,7 +311,7 @@ static const char *get_type (parsed_symbol *sym, const char *proto, int arg)
if (arg < 0) if (arg < 0)
{ {
sym->return_text = (char*)type_str; sym->return_text = type_str;
sym->return_type = dest_type; sym->return_type = dest_type;
} }
else else
...@@ -332,7 +332,7 @@ static const char *get_type (parsed_symbol *sym, const char *proto, int arg) ...@@ -332,7 +332,7 @@ static const char *get_type (parsed_symbol *sym, const char *proto, int arg)
sym->arg_name [arg] = str_substring (proto_str, iter); sym->arg_name [arg] = str_substring (proto_str, iter);
proto_str = iter; proto_str = iter;
} }
sym->arg_text [arg] = (char*)type_str; sym->arg_text [arg] = type_str;
} }
return proto_str; return proto_str;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment