Pulled buffering outside function