Author: cgutman
Date: Wed Mar 25 05:28:40 2009
New Revision: 40215
URL:
http://svn.reactos.org/svn/reactos?rev=40215&view=rev
Log:
- Fix ICMP
Modified:
trunk/reactos/lib/drivers/ip/transport/rawip/rawip.c
Modified: trunk/reactos/lib/drivers/ip/transport/rawip/rawip.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/drivers/ip/transport/r…
==============================================================================
--- trunk/reactos/lib/drivers/ip/transport/rawip/rawip.c [iso-8859-1] (original)
+++ trunk/reactos/lib/drivers/ip/transport/rawip/rawip.c [iso-8859-1] Wed Mar 25 05:28:40
2009
@@ -191,7 +191,7 @@
{
IP_PACKET Packet;
PTA_IP_ADDRESS RemoteAddressTa = (PTA_IP_ADDRESS)ConnInfo->RemoteAddress;
- IP_ADDRESS RemoteAddress;
+ IP_ADDRESS RemoteAddress, LocalAddress;
USHORT RemotePort;
NTSTATUS Status;
PNEIGHBOR_CACHE_ENTRY NCE;
@@ -212,10 +212,17 @@
return STATUS_UNSUCCESSFUL;
}
+ LocalAddress = AddrFile->Address;
+ if (AddrIsUnspecified(&LocalAddress))
+ {
+ if (!IPGetDefaultAddress(&LocalAddress))
+ return STATUS_UNSUCCESSFUL;
+ }
+
Status = BuildRawIpPacket( &Packet,
&RemoteAddress,
RemotePort,
- &AddrFile->Address,
+ &LocalAddress,
AddrFile->Port,
BufferData,
DataSize );