Minimize the scope of the temp buffer.