X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Fvpn%2Fgnunet-service-vpn.c;h=4759f374661e0ba46c4969ee0383ba5e8eade6a6;hb=5b085881ab278a85c3ef3a1d91c58a5724a4e430;hp=aa0ea51a32085a0a6d74249973bb3640a4bb8d48;hpb=88a0df3dcc38c6e82f483bff386c87d8e1ec4459;p=oweals%2Fgnunet.git diff --git a/src/vpn/gnunet-service-vpn.c b/src/vpn/gnunet-service-vpn.c index aa0ea51a3..4759f3746 100644 --- a/src/vpn/gnunet-service-vpn.c +++ b/src/vpn/gnunet-service-vpn.c @@ -1384,7 +1384,7 @@ create_channel (struct ChannelState *ts, GNUNET_MQ_handler_end() }; - return GNUNET_CADET_channel_creatE (cadet_handle, + return GNUNET_CADET_channel_create (cadet_handle, ts, target, port, @@ -2061,6 +2061,7 @@ route_packet (struct DestinationEntry *destination, void *payload; uint8_t new_type; + new_type = icmp->type; /* Perform ICMP protocol-translation (depending on destination AF and source AF) and throw away ICMP payload depending on ICMP message type */ switch (af) @@ -2111,8 +2112,8 @@ route_packet (struct DestinationEntry *destination, switch (icmp->type) { case GNUNET_TUN_ICMPTYPE6_DESTINATION_UNREACHABLE: - if (destination->details.exit_destination.af == AF_INET6) - new_type = GNUNET_TUN_ICMPTYPE6_DESTINATION_UNREACHABLE; + if (destination->details.exit_destination.af == AF_INET) + new_type = GNUNET_TUN_ICMPTYPE_DESTINATION_UNREACHABLE; /* throw away IP-payload, exit will have to make it up anyway */ payload_length = sizeof (struct GNUNET_TUN_IcmpHeader); break; @@ -2216,12 +2217,10 @@ route_packet (struct DestinationEntry *destination, * and forward the packet. * * @param cls closure, NULL - * @param client NULL * @param message message we got from the client (VPN channel interface) */ static int message_token (void *cls, - void *client, const struct GNUNET_MessageHeader *message) { const struct GNUNET_TUN_Layer2PacketHeader *tun; @@ -3067,7 +3066,7 @@ run (void *cls, } vpn_argv[6] = NULL; - cadet_handle = GNUNET_CADET_connecT (cfg_); + cadet_handle = GNUNET_CADET_connect (cfg_); // FIXME never opens ports??? helper_handle = GNUNET_HELPER_start (GNUNET_NO, "gnunet-helper-vpn", vpn_argv,