Closed roytam1 closed 12 years ago
Hi,
Thanks for the patch! Would you mind make a couple of alterations?
Using MINGW32 means that it will only work with that compiler (and not with eg. MSVC). According to this, _WIN32 looks like it would be a better choice:
http://sourceforge.net/apps/mediawiki/predef/index.php?title=Operating_Systems#Windows
Is the change to lha_input_stream.c really necessary? ANSI C lets you cast (void *) to any pointer type, so I'm not sure why the intermediate variable is necessary.
Using MINGW32 means that it will only work with that compiler (and not with eg. MSVC). According to this, _WIN32 looks like it would be a better choice:
http://sourceforge.net/apps/mediawiki/predef/index.php?title=Operating_Systems#Windows
I didn't test on MSVC.
Is the change to lha_input_stream.c really necessary? ANSI C lets you cast (void *) to any pointer type, so I'm not sure why the intermediate variable is necessary.
I'm not sure if MinGW's feof() accept such casting as MinGW's feof() dereferences the pointer.
I didn't test on MSVC.
I appreciate that; just saying: there are a lot of different compilers available on Windows. _WIN32 seems like a better choice if MingW32 supports it, which it looks like it does.
I'm not sure if MinGW's feof() accept such casting as MinGW's feof() dereferences the pointer.
Ah, I see. Fair enough.
I fixed up your patch and committed it. Thanks!
I'd just hacked around it(especially the file-related APIs). PMA archive and -lh0- works in windows.