Wireshark-dev: Re: [Wireshark-dev] Patch to epan/dissectors/packet-lapd.c, some-one please appl
From: "Anders Broman" <a.broman@xxxxxxxxx>
Date: Thu, 21 Sep 2006 21:40:34 +0200
>Hi Jaap,

>thank you for your reply. I understand your concern, so I would like to 
>present my view of things.
>It would be best if SVN user etxrab could also comment on this, after 
>all her/his patch broke network/user display on ISDN captures.

I just checked in a patch sent by someone else to the list.

>The traditional ethereal convention is that the device capturing the 
>data sits on the user side of an ISDN link, so SENT means sent by TE 
>(user) and RECV means sent by NT (network). This conventions is quite 
>reasonable, since most wireshark users capture on the user side.

>The patch by etxrab added the possibility to be either on the network or 
>on the user side, but only for a specific capture type. For all other 
>cases, the old behaviour should stay.

>The code is like
>if(pinfo->fd->lnk_t == WTAP_ENCAP_LINUX_LAPD) {
>   check if capturing on net or user side and setting src and dst 
>accordingly.
>   this was added for vISDN capturing by adding a new capture type to 
>libpcap
>} else {
>   the other case is for all old isdn captures and should have stayed 
>the same.
>   however, it was swapped, I assume accidentially
>   here is should always be
>   if SENT: src=User, dst=Network
>   if RECV: src=Network, dst=User
>}
>
>extrab, please confirm this description.

Looking at the code it sounds reasonable.

>I hope this helps to clear up the situation.
>By the way, I know the person who posted bug 965 personally (but we 
>haven't spoken about this issue). My patch from bug 1106 would also 
>close bug 965, both bugs are essentially the same.
>

So the bug 965 is for the lapd dissector not the Q.931 one?
I've added the following comment to the Q.931 dissector:
/*
 * NOTE  For call reference flag (octet 2)
 * Bit8
 *	0 The message is sent from the side that originates the call
reference
 *	1 The message is sent to the side that originates the call reference
 */

>Greetings,
>Rolf

>PS: another way of looking at this issue: the patch by extrab swapped 
>net/user for all existing users of packet-lapd and so now shows false 
>information. It was ok before, since March this year Network and User 
>are swapped.

Ok I've checked in your fix.

Best regards
Anders