i am getting a compiler warning, here's the code:
uint8 executeSpecialCommand(const char *string)
{
char *parameters;
parameters = strtok(string, "=");
if (parameters)
{
usbSendf("\nProcessing Parameters...");
while(parameters != NULL)
{
parameters = strtok(NULL, " ");
usbSendf("\n%s", parameters);
}
return 1;
}
else
return 0;
}
the error points to line 3 and i think it is because "=". strtok is expecting a const char* somehow in other parts of the code i use the same and i get no warning. An ideas here to help educate me ?
UPDATE The error i get is:
warning 196: pointer target lost const qualifier
thanks