corrected sign of buffer