A
Andre
Hi All,
When I compile the following piece of code with gcc, I get 3 "warning:
initialization discards qualifiers from pointer target type" messages
which refer to the 3 lines marked in the code. What's wrong with
these lines? I searched the web for it, but didn't find anything
useful.
Thanks,
Andre
enum CompressionType {
DEFLATE = 0,
GZIP
};
struct CompressionInfo {
char * Name;
int32_t Type;
uint32_t WindowSize;
};
static struct CompressionInfo compression_table[] = {
{ "deflate", DEFLATE, DEFLATE_WINDOW_SIZE }, <-- HERE
{ "gzip", GZIP,
24 }, <-- HERE
{ "", -1,
0 } <-- HERE
};
When I compile the following piece of code with gcc, I get 3 "warning:
initialization discards qualifiers from pointer target type" messages
which refer to the 3 lines marked in the code. What's wrong with
these lines? I searched the web for it, but didn't find anything
useful.
Thanks,
Andre
enum CompressionType {
DEFLATE = 0,
GZIP
};
struct CompressionInfo {
char * Name;
int32_t Type;
uint32_t WindowSize;
};
static struct CompressionInfo compression_table[] = {
{ "deflate", DEFLATE, DEFLATE_WINDOW_SIZE }, <-- HERE
{ "gzip", GZIP,
24 }, <-- HERE
{ "", -1,
0 } <-- HERE
};