X-Git-Url: https://tinc-vpn.org/git/browse?p=tinc;a=blobdiff_plain;f=src%2Fnet.c;h=dc632b608f457defcdde384a6c27b24021233a34;hp=58f3e02fbedba61472c062e890b7f9d9f262d1c8;hb=ee96ccabbbf0180d5631d3c22838456f28ee9c15;hpb=d0ba34ccae02d07051bc3f7012a6c116cfb3b653 diff --git a/src/net.c b/src/net.c index 58f3e02f..dc632b60 100644 --- a/src/net.c +++ b/src/net.c @@ -1,6 +1,6 @@ /* net.c -- most of the network code - Copyright (C) 1998,99 Ivo Timmermans + Copyright (C) 1998,1999,2000 Ivo Timmermans This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -258,14 +258,8 @@ cp */ int send_packet(ip_t to, vpn_packet_t *packet) { - config_t const *cfg; conn_list_t *cl; cp - if(!(cfg = get_config_val(proxymode))) /* In case we are in proxy mode, just send everything to our uplink. */ - cl = conn_list; - else - cl = lookup_conn(to); - if((cl = lookup_conn(to)) == NULL) { if(debug_lvl > 2) @@ -310,21 +304,6 @@ cp return xsend(cl, packet); } -int send_broadcast(conn_list_t *cl, vpn_packet_t *packet) -{ - conn_list_t *p; -cp - for(p = cl; p != NULL; p = p->next) - if(send_packet(p->real_ip, packet) < 0) - { - syslog(LOG_ERR, "Could not send a broadcast packet to %08lx (%08lx): %m", - p->vpn_ip, p->real_ip); - break; /* FIXME: should retry later, and send a ping over the metaconnection. */ - } -cp - return 0; -} - /* open the local ethertap device */