Fixed bug on multicore writer