Used for asynchronous GetMessages completion.