diff options
author | Philipp Tölke <toelke@in.tum.de> | 2010-10-03 17:24:26 +0000 |
---|---|---|
committer | Philipp Tölke <toelke@in.tum.de> | 2010-10-03 17:24:26 +0000 |
commit | 12b9ea4eebe332f034e1de8bacfc688b6fc7f0d4 (patch) | |
tree | e8126053f0d8cc34b386d36db3973ffdfe0a3189 /src/vpn/gnunet-helper-vpn.c | |
parent | ea1b2ef20220e996cfc57a82e081370359e025cf (diff) | |
download | gnunet-12b9ea4eebe332f034e1de8bacfc688b6fc7f0d4.tar.gz gnunet-12b9ea4eebe332f034e1de8bacfc688b6fc7f0d4.zip |
-Stop the vpn-helper if an invalid message arrives
-Note that restarting the helper demands restarting the hijacker, too
Diffstat (limited to 'src/vpn/gnunet-helper-vpn.c')
-rw-r--r-- | src/vpn/gnunet-helper-vpn.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/vpn/gnunet-helper-vpn.c b/src/vpn/gnunet-helper-vpn.c index 459f2f491..4a367e9c9 100644 --- a/src/vpn/gnunet-helper-vpn.c +++ b/src/vpn/gnunet-helper-vpn.c | |||
@@ -221,6 +221,7 @@ outer: | |||
221 | wri=0; | 221 | wri=0; |
222 | goto outer; | 222 | goto outer; |
223 | } | 223 | } |
224 | if(pkt->hdr.type != ntohs(GNUNET_MESSAGE_TYPE_VPN_HELPER)) abort(); | ||
224 | while (r < ntohs(pkt->hdr.size)) { | 225 | while (r < ntohs(pkt->hdr.size)) { |
225 | int t = read(0, buf + r, ntohs(pkt->hdr.size) - r); | 226 | int t = read(0, buf + r, ntohs(pkt->hdr.size) - r); |
226 | if (r < 0) { | 227 | if (r < 0) { |