Fix a leak of the scratch buffer array in the dummy session: don't allocate scratch buffers until we have a real session.