Originally Posted by
ArkM
Is it so hard job to correct obvious errors: you get compiler messages on wrong function arguments: fread and fwrite want POINTERS to target/source data areas (&d - not d, &b - not b))!
Use code tag properly:
[code=c]
source
[/code]
Never use dangerous gets function: it does not check target buffer size. Use fgets instead of gets:
fgets(fn,sizeof fn,sdtin);
With gets you program crashed if the file name length is greater than 49.
Don't forget to append carriage return:
printf("\nFile saved\n");
Avoid using of non-standard function flushall().
thanks ArkM. Now I can do storing and getting data from files with integers and floats. Thanks for the tips too. I'm really slow. It's hard for me to solve obvious errors that I haven't encountered before..
Last edited by Whilliam; Nov 24th, 2008 at 7:19 am.