final fixes for buffering