The previous fix for glPopAttrib was incomplete.