hot fix buffer handling