When both logging and sending the DTMF event further, the json buffer was released/freed _before_ being sent on the network, resulting in a 0-length UDP packet. On the other hand, if only UDP sending was used (without logging), a leak was happening. This commit fixes both issues.pull/797/head