don't use unwind-protect here.  Memory should be deallocated only if message received successfully