in reply to Is there a way to control when output gets printed to a file?
However, it is the opinion of some that you should explicitly open and close the log file on every print (or group of prints) so that you can rotate/move or (accidentally?) delete the log file while the program is running, and not lose any further output and have output continue to go to a file with the same name. And if it doesn't spend most of its time making log entries, it won't slow anything down significantly.
|
|---|