write error stream separately