From: Ian Jackson Date: Sat, 21 Sep 2019 14:21:09 +0000 (+0100) Subject: udp: Use commcommon->why_unwanted X-Git-Tag: v0.5.0~8 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=secnet.git;a=commitdiff_plain;h=063a38452284a02b339100f3d62eebf12b128dfd udp: Use commcommon->why_unwanted This is the one call site of comm_notify. (If we had had any comm that wasn't based on udp.c, that would have needed updating too.) No overall functional change: nothing ever sets this yet, so we always use the default message. Signed-off-by: Ian Jackson --- diff --git a/udp.c b/udp.c index b9a3860..d1ada01 100644 --- a/udp.c +++ b/udp.c @@ -186,7 +186,9 @@ static void udp_socks_afterpoll(void *state, struct pollfd *fds, int nfds) /* Manufacture and send NAK packet */ source=get_uint32(cc->rbuf->start); /* Us */ dest=get_uint32(cc->rbuf->start+4); /* Them */ - send_nak(&ca,source,dest,msgtype,cc->rbuf,"unwanted"); + send_nak(&ca,source,dest,msgtype,cc->rbuf, + priomsg_getmessage(&cc->why_unwanted, + "unwanted")); } BUF_FREE(cc->rbuf); }