avoid TextStream which breaks .copy()'s contract