Fix strdup/malloc/free ordering to always free the right pointer.

This commit ensures that udp_send_msg is freed before being reallocated
and freed before the process exits. This also changes the last fprintf
to a log_warn() call, which should be more inline with the intent.
Arguments in error message were swapped, fix
Merge pull request #13 from hmoore-r7/bug/fix-udp-malloc-free

Fix strdup/malloc/free ordering to always free the right pointer.