Multiple payloads in a single message

This patch alters the code so that it handles the case were the server packs multiple messages into one record.  There is also a second patch in this set which alters the script to work under python 2.4.