Warning messages
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Warning messages



I am getting the following warning messages in my code:

 

"warning: pointer targets in passing argument 1 of 'OSGetINI' differ in
signedness"

 

These warnings occur when I have declared the function with 'unsigned
char *someparametername' and I want to pass a constant string in the
function call. Example:

 

void somefunction(unsigned char *someparametername);

 

..

..

..

            Somefunction("This constant string");

..

..

..

 

When I switch these warnings off with the compiler option
'-Wno-pointer-sign' these warnings are suppressed, but my question is
now when a real problem occurs like this example:

 

void somefunction(unsigned char *someparametername);

 

signed char *somesignedvariable;

 

...

...

Somefunction(somesignedvariable);

...

...

Is this going to get the warning still or is this warning also
suppressed?

 

If so is there another way to stop the warnings from the first example
and still detect the warnings from the second?

 

John.