Better buffer management