util.c: Use low-level open/write/close calls to write log files
util.c: Use low-level open/write/close calls to write log files

This will make sure that stuff that has been written has actually been
written to the log files after ncdc crashes. It doesn't ensure that it
has also been flushed to disk, but that isn't nearly as important.

Tilka/ncdc,Tilka/ncdc,srijan/ncdc,srijan/ncdc,srijan/ncdc