udp: fix potential deadlock at exit
udp: fix potential deadlock at exit

(cherry picked from commit 613ea43a83ed745a9dd58ebce89607b98dbe894c)
Signed-off-by: Jean-Baptiste Kempf <7b85a41a628204b76aba4326273a3ccc74bd009a@videolan.org>

jomanmuk/vlc-2.2,jomanmuk/vlc-2.2,jomanmuk/vlc-2.2,jomanmuk/vlc-2.2,jomanmuk/vlc-2.2,jomanmuk/vlc-2.2,jomanmuk/vlc-2.2