ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

PNEIGHBOR_CACHE_ENTRY RouteGetRouteToDestination ( PIP_ADDRESS  Destination)

Definition at line 301 of file router.c.

Referenced by ICMPSendDatagram(), ICMPTransmit(), RawIPSendDatagram(), TCPConnect(), TCPSendDataCallback(), and UDPSendDatagram().

{
    PNEIGHBOR_CACHE_ENTRY NCE = NULL;
    PIP_INTERFACE Interface;

    TI_DbgPrint(DEBUG_RCACHE, ("Called. Destination (0x%X)\n", Destination));

    TI_DbgPrint(DEBUG_RCACHE, ("Destination (%s)\n", A2S(Destination)));

#if 0
    TI_DbgPrint(MIN_TRACE, ("Displaying tree (before).\n"));
    PrintTree(RouteCache);
#endif

    /* Check if the destination is on-link */
    Interface = FindOnLinkInterface(Destination);
    if (Interface) {
    /* The destination address is on-link. Check our neighbor cache */
    NCE = NBFindOrCreateNeighbor(Interface, Destination, FALSE);
    } else {
    /* Destination is not on any subnets we're on. Find a router to use */
    NCE = RouterGetRoute(Destination);
    }

    if( NCE )
    TI_DbgPrint(DEBUG_ROUTER,("Interface->MTU: %d\n", NCE->Interface->MTU));

    return NCE;
}

Generated on Sat May 26 2012 05:09:18 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.