From owner-freebsd-hackers Wed May 22 11:09:15 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id LAA14915 for hackers-outgoing; Wed, 22 May 1996 11:09:15 -0700 (PDT) Received: from trem.cnt.org.br (desvio.cnt.org.br [200.19.123.2]) by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id LAA14899 for ; Wed, 22 May 1996 11:08:59 -0700 (PDT) Received: by trem.cnt.org.br (AIX 3.2/UCB 5.64/4.03) id AA08687; Wed, 22 May 1996 15:07:11 -0300 From: ormonde@trem.cnt.org.br (Rodrigo Ormonde) Message-Id: <9605221807.AA08687@trem.cnt.org.br> Subject: NULL interface field in ip_fw_chk To: freebsd-hackers@freebsd.org Date: Wed, 22 May 1996 15:07:11 -0300 (GRNLNDST) X-Mailer: ELM [version 2.4 PL24] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hi folks. I'm working in the ip_fw.c module in the FreeBSD 2.1. There is a function in this module called ip_fw_chk that returns TRUE or FALSE if the ip packet that it receives should or not be accepted (i.e. routed by ip). This function receives 4 parameters and one of them is a pointer to a structure that holds information about the interface the packet comes from. The prototype of the function is: int ip_fw_chk(mbuf *m, struct ip *ip, struct ifnet *rif, ... Looking into the code of ip_fw_chk, I realise that sometimes this function is called with rif = NULL. My question is: does anybody knows why and under what circunstances the ip_fw_chk is called with a NULL pointer in the interface field ? (the ip_fw_chk function is called only by ip_input.c) Thanks in advance for your help. -- Rodrigo de La Rocque Ormonde Confederacao Nacional do Transporte e-mail: ormonde@cnt.org.br