[writeboost] fix: kfree(buf) places wrongly

In format_all_segment_headers(), the buffer is freed
although the buffer is still used.

Signed-off-by: Akira Hayakawa <ruby.wktk@gmail.com>