Build tools: Fix warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

git-svn-id: https://svn.eduke32.com/eduke32@6038 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
hendricks266 2017-01-23 11:20:54 +00:00
parent 05b311b72a
commit 6b6167c148
8 changed files with 11 additions and 9 deletions

View file

@ -6,7 +6,6 @@
#include "compat.h"
#define DEFAULT_OUTPUT_FILE "enumdisplay.txt"
char *outputfile = DEFAULT_OUTPUT_FILE;
HMODULE hDDrawDLL = NULL;
LPDIRECTDRAW lpDD = NULL;
@ -88,6 +87,8 @@ void UninitDirectDraw(void)
int main(int argc, char **argv)
{
char const * outputfile = DEFAULT_OUTPUT_FILE;
int i;
DEVMODE devmode;

View file

@ -9,7 +9,7 @@
#include <stdio.h>
#include "compat.h"
char *WhatGUID(const GUID *guid)
char const * WhatGUID(const GUID *guid)
{
if (guid == &GUID_XAxis) return "&GUID_XAxis";
if (guid == &GUID_YAxis) return "&GUID_YAxis";

View file

@ -69,7 +69,7 @@ int main(void)
continue;
}
else {
char *format;
char const * format;
char flags[4] = "", flagsc = 0;
switch (mip.format) {
case GL_COMPRESSED_RGB_S3TC_DXT1_EXT: format = "RGB DXT1"; break;

View file

@ -34,7 +34,7 @@ fail:
int main(int argc, char **argv)
{
char *palfile = "palette.dat", *voxfile = "output.vox";
char const * palfile = "palette.dat", * voxfile = "output.vox";
int tilenum;
int depth;
FILE *artfh, *voxfh, *palfh;

View file

@ -21,7 +21,7 @@ static char filespec[MAXFILES][128], filelist[MAXFILES][16];
static int fileleng[MAXFILES];
static char *matchstr = "*.*";
static char const * matchstr = "*.*";
int checkmatch(const struct Bdirent *a)
{
if (a->mode & BS_IFDIR) return 0; // is a directory
@ -46,7 +46,8 @@ void findfiles(const char *dafilespec)
{
struct Bdirent *name;
int daspeclen;
char daspec[128], *dir;
char daspec[128];
char const * dir;
BDIR *di;
strcpy(daspec,dafilespec);

View file

@ -31,7 +31,7 @@ int main(int argc, char **argv)
unsigned char rgbout[3];
int idx, step, rampnum;
FILE* fh;
char *outfile = "palette.dat";
char const * outfile = "palette.dat";
memset(palette,0,sizeof(palette));

View file

@ -107,7 +107,7 @@ void savenames(void)
}
}
void showart (char *part)
void showart (char const * part)
{
char yoff;
short xsiz, ysiz;

View file

@ -897,7 +897,7 @@ void setsectorfield(int i, int fieldnum, int newval)
}
}
int getwadindex(char *nam)
int getwadindex(char const * nam)
{
int i, j;