Fix getWriteBuffer bug in cache_impl.hh