I simply allocate some memory for a character and wanna do then some pointer arithmetic. In this case I wanna write '\x0a' to byte 32 as follows:
#define HDR_SIZE 32
int size = 52;
unsigned char *readXPacket = (unsigned char *) malloc (size * sizeof (unsigned char));
*readXPacket + HDR_SIZE = '\x0a';
When I try doing that I get the following error message: non-value in assignment. Anyone an idea what is wrong here?
Thanks