📄 igmp_receive.c
字号:
/*
$Log:: /OEM Source Code/igmp/igmp_receive.c $
*
* 1 4/23/98 9:53p Release Engineer
* Initial release
* IGMP v4.1.0
*/
/************************************************************************/
/* Copyright (C) 1997-1998 RouterWare, Inc. */
/* Unpublished - rights reserved under the Copyright Laws of the */
/* United States. Use, duplication, or disclosure by the */
/* Government is subject to restrictions as set forth in */
/* subparagraph (c)(1)(ii) of the Rights in Technical Data and */
/* Computer Software clause at 252.227-7013. */
/* RouterWare, Inc., 3961 MacArthur Blvd. Suite 212, Newport Beach, CA */
/************************************************************************/
#include "igmp.h"
/********************************************************************************************/
void igmp_receive_packet (IP_PARAMETERS *sptr_ip_parameters,void *sptr_igmp_received_packet,
USHORT igmp_packet_size)
{
IGMP_MESSAGE *sptr_igmp_message;
UINT port;
sptr_igmp_message = igmp_deserialize_received_message (sptr_ip_parameters, sptr_igmp_received_packet, igmp_packet_size);
if (sptr_igmp_message == NULL)
{
return;
}
IGMP_PROTOCOL_TRACE (IGMP_TRACE, "IGMP: RECEIVED an IGMP message on port %u.\n", sptr_ip_parameters->rx_port_number);
IGMP_PROTOCOL_TRACE_DISPLAY_MESSAGE (sptr_ip_parameters->source_address, sptr_ip_parameters->destination_address,
sptr_igmp_message->type, sptr_igmp_message->max_response_time, sptr_igmp_message->group_ip_address);
port = sptr_igmp_message->receiving_port;
if (igmp.port_table[port].router_enabled == TRUE)
{
igmp_router_process_received_message (sptr_igmp_message);
}
if (igmp.port_table[port].host_enabled == TRUE)
{
igmp_host_process_received_message (sptr_igmp_message);
}
igmp_free_message (sptr_igmp_message);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -