Quote:
Originally Posted by roondar
However, my compiled-under-windows version of diskimage.c (from the Solid Gold Source) does very odd stuff.
|
I suppose it uses fopen(filename,"w"). This means that the contents is treated as text and on a DOS/Windows machine each newline character ($0a) gets a carriage return ($0d) added to it.
Change this to fopen(filename,"wb"), then the contents will be treated as binary and written as is.
The same is true for "r", then every $0d before a $0a will be filtered out. Change this to "rb", too.