|
-
June 17th, 2002, 05:01 AM
#4
Never use sintax like this, or it provide many bugs:
1) whay should we read and write file in memory, throw all the filtres, we can coll CopyFile() or MoveFile(), it optimized by the OS.
2) aspecialy for 'fstreams' they are incorrectly working with '\n', '\r' symbols, so in case of this syntax you will get new file with doubbled '\n' ...
ifstream inputFile("c:\\temp.txt",ios::binary);
ofstream outputFile("c:\\temp2.txt",ios::binary);
outputFile << inputFile.rdbuf();
for detailed usage, you can go to MSDN library
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|