- Timestamp:
- Oct 30, 2015 12:17:00 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/NetworkServices/NAT/pxtcp.c
r58507 r58509 907 907 struct netif *netif, struct pbuf *p) 908 908 { 909 struct netif *oif;910 909 int reset = 0; 911 912 oif = ip_current_netif();913 ip_current_netif() = netif;914 910 915 911 if (sockerr == ECONNREFUSED) { 916 912 reset = 1; 917 913 } 918 else if (PCB_ISIPV6(pcb)) { 919 if (sockerr == EHOSTDOWN) { 920 icmp6_dest_unreach(p, ICMP6_DUR_ADDRESS); /* XXX: ??? */ 921 } 922 else if (sockerr == EHOSTUNREACH 923 || sockerr == ENETDOWN 924 || sockerr == ENETUNREACH) 925 { 926 icmp6_dest_unreach(p, ICMP6_DUR_NO_ROUTE); 927 } 928 } 929 else { 930 if (sockerr == EHOSTDOWN 931 || sockerr == EHOSTUNREACH 932 || sockerr == ENETDOWN 933 || sockerr == ENETUNREACH) 934 { 935 icmp_dest_unreach(p, ICMP_DUR_HOST); 936 } 937 } 938 939 ip_current_netif() = oif; 914 else if (p != NULL) { 915 struct netif *oif; 916 917 LWIP_ASSERT1(netif != NULL); 918 919 oif = ip_current_netif(); 920 ip_current_netif() = netif; 921 922 if (PCB_ISIPV6(pcb)) { 923 if (sockerr == EHOSTDOWN) { 924 icmp6_dest_unreach(p, ICMP6_DUR_ADDRESS); /* XXX: ??? */ 925 } 926 else if (sockerr == EHOSTUNREACH 927 || sockerr == ENETDOWN 928 || sockerr == ENETUNREACH) 929 { 930 icmp6_dest_unreach(p, ICMP6_DUR_NO_ROUTE); 931 } 932 } 933 else { 934 if (sockerr == EHOSTDOWN 935 || sockerr == EHOSTUNREACH 936 || sockerr == ENETDOWN 937 || sockerr == ENETUNREACH) 938 { 939 icmp_dest_unreach(p, ICMP_DUR_HOST); 940 } 941 } 942 943 ip_current_netif() = oif; 944 } 940 945 941 946 tcp_abandon(pcb, reset);
Note:
See TracChangeset
for help on using the changeset viewer.