Background: I am receiving a array as char* as a part of socket session. Now we have to match the Tokens (HTTP headers) out of it.Code here is that we have created a UBYTE* and getting the value from the char array after typecasting with UBYTE. Later same UBYTE pointer we are passing to other function which accepts char* after typecasting it to char*.
Problem here is this works in release build and not in debug build (with -g and different optimization). Not only this adding few prints in debug mode hide the problem.
So my queestion here, What is the difference between UByte pointer(which is essentially a unsigned char) and char pointer. Changing UByte to char is solving my problem in all modes but I dont have any explaination for the same? Any thoughts ?