Added fix to server code that adjusts for when partial messages are received