Restore default error handling when MessagingHandler is used
PROTON-772: Remove all direct printing to stdout and stderr (missed one)

Added a check to ensure we don't log any transport trace messages unless at least
one of the trace modes is enabled.