I'm having a bit of trouble with making the buffer while making recover on PSET4. I have tried a couple different things, but I keep getting the same error regardless of the fix I try:
recover.c:25:40: error: excess elements in char array initializer [-Werror] unsigned char compare[] = {"0xff", "0xd8", "0xff"}; (The 0xd8 was underlined in the cs50 IDE)
I have tried to use both BYTE's, char arrays, unsigned char arrays (could someone please tell me if i have correctly understood this? - It is a char that denotes a number from 0 to 255), and char.
Byte
typedef uint8_t BYTE;
BYTE buffer[512];
BYTE compare[] = {"0xff", "0xd8", "0ff"};
unsigned char
unsigned char buffer[512];
unsigned char compare[] = {"0xff", "0xd8", "0ff"};
char
char buffer[512];
char compare[] = {"0xff", "0xd8", "0ff"};