PAPI-1117: Fix the copy of messages from one queue to another.