Fix  a bug when null value is buffered