Line 25 is the likely culprit. U need to allocate memory with malloc/free or the c++ keywords new/delete (preferred) which stores the bytes returned from fread.
1) Please use code tags (the <> button) when posting code.
2) I received no errors when compiling the code after having to manually remove every line number (ugh).
3) Please post the full text of the error you're getting including the line number reported by the compiler.
@soranz - I see no issue with line 25. buf1 is defined at line 9 and is allocated as 32K bytes.
@AbstractionAnon Ah ok u're right. I saw the #define SWAP64 but i missed the other one for BS and declaration of buf1. Didn't even try to compile with those line #s in there lol
I posted the line numbers for easier communication.
What compiler are you using?
the line(s) that the compiler chokes on is 40, 41, and 52 the message is
40: error:expected primary-expression before 'unsigned'
I posted the line numbers for easier communication.
Appreciated but the code tags
[code]//code in here[code]
do this automatically and are formatted to not copy line numbers when we try out the code posted.
About the errors I don't know what the problem is exactly...It did compile for me too. I'll just say that I see a whole lot of casting and I'm wondering if it's all necessary ?
Thanks. Next time I'll follow the format rules.
For the error, I think it must be the compiler I'm using. It's good that it compiled for you and AbstractionAnon.