Commit c5bc2647 authored by Robert Shearman's avatar Robert Shearman Committed by Alexandre Julliard

Fix -Wwrite-strings warnings.

parent f9cad774
......@@ -226,7 +226,7 @@ static int dump_pidl(int fd)
return 0;
}
static void print_unicode_string(unsigned short *str)
static void print_unicode_string(const unsigned short *str)
{
while(*str)
{
......@@ -236,7 +236,7 @@ static void print_unicode_string(unsigned short *str)
printf("\n");
}
static int dump_string(int fd, char *what, int unicode)
static int dump_string(int fd, const char *what, int unicode)
{
lnk_string *data;
......@@ -300,7 +300,7 @@ static int dump_location(int fd)
return 0;
}
static int dump_advertise_info(int fd, char *type)
static int dump_advertise_info(int fd, const char *type)
{
LINK_ADVERTISEINFO *avt;
......
......@@ -225,7 +225,7 @@ void mdmp_dump(void)
case SystemInfoStream:
{
MINIDUMP_SYSTEM_INFO* msi = (MINIDUMP_SYSTEM_INFO*)stream;
char* str;
const char* str;
char tmp[128];
printf("System Information:\n");
......
......@@ -69,7 +69,8 @@ int symbol_demangle (parsed_symbol *sym)
int is_static = 0, is_const = 0;
char *function_name = NULL;
char *class_name = NULL;
char *name, *const_status;
char *name;
const char *const_status;
static unsigned int hash = 0; /* In case of overloaded functions */
unsigned int data_flags = 0;
......@@ -673,7 +674,7 @@ static char *get_constraints_convention_2 (char **str, compound_type *ct)
*/
static char *get_type_string (const char c, const int constraints)
{
char *type_string;
const char *type_string;
if (constraints & CT_EXTENDED)
{
......
......@@ -113,7 +113,7 @@ static const char* DirectoryNames[16] = {
static void dump_pe_header(void)
{
char *str;
const char *str;
IMAGE_FILE_HEADER *fileHeader;
IMAGE_OPTIONAL_HEADER *optionalHeader;
unsigned i;
......@@ -931,7 +931,7 @@ static void do_grab_sym( enum FileSig sig, void* pmt )
DWORD* pName;
DWORD* pFunc;
WORD* pOrdl;
char* ptr;
const char* ptr;
DWORD* map;
PE_nt_headers = pmt;
......
......@@ -131,7 +131,7 @@ typedef struct __globals
char *directory; /* -I */
const char *forward_dll; /* -f */
const char *dll_name; /* -o */
char *uc_dll_name; /* -o */
const char *uc_dll_name; /* -o */
/* Option arguments: dump mode */
const char *dumpsect; /* -j */
......
......@@ -27,8 +27,8 @@ typedef struct language {
unsigned id;
unsigned doscp;
unsigned wincp;
char *name;
char *country;
const char *name;
const char *country;
} language_t;
void show_languages(void);
......
......@@ -470,7 +470,7 @@ static void write_rcinline(FILE *fp)
{
char *cptr;
int l = blk->msgs[j]->len;
char *comma = j == blk->nmsg-1 && i == lbp->nblk-1 ? "" : ",";
const char *comma = j == blk->nmsg-1 && i == lbp->nblk-1 ? "" : ",";
cptr = make_string(blk->msgs[j]->msg, l, unicodeout ? 0 : blk->msgs[j]->cp);
fprintf(fp, "\n /* Msg 0x%08x */ 0x%04x, 0x000%c,\n",
blk->idlo + j,
......
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