Payload::Base.to_s doesn't reset stream position

Payload::Base.to_s doesn't reset stream position so calling it twice (or more) will return empty. Not sure if this was the expected behaviour, but I didn't seem right to me, so I did a test and a fix for it.