Use of writeLog & writeErr