added waiting to buffer