My professor has instructed me that we can lay a struct over (casting) the pointer in memory we are getting in order to more easily interpret the data. I asked about this in class today and this is what he said would work.
This is not compiling complaining about how it can't cast it. What am I doing wrong? I am about to resort to parsing the data manually...
struct DataStruct
{
u_char DEST_ADDRESS[6];
u_char SOURCE_ADDRESS[6];
};
struct DataStruct* testData;
testData = (struct DataStruct*)pkt_data;