[Xorp-hackers] [PIM] Setting a bit in the Encoded source address

chintamani wandhre chintamanisw at gmail.com
Tue Mar 6 08:07:35 PST 2007


hello,
We have to set the bidirectional bit in the ENCODED GROUP ADDRESS


 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|  Addr Family  | Encoding Type |B| Reserved  |Z|  Mask Len     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                Group multicast Address
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+...

By using following function we can get octet but how can we set the single
bit ( B )?  :)

i could not get the flow in the following code :

#define GET_OCTET(val, cp, rcvlen)                      \
do {                                                                    \
    if ((size_t)(rcvlen) < (size_t)1)                            \
        goto rcvlen_error;                                         \
    (rcvlen)--;                                                         \
    ((val) = *(cp)++);                                               \
} while (0)

thanking you in anticipation

shamita
ashish
chintamani
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/xorp-hackers/attachments/20070306/8f590b92/attachment.html 


More information about the Xorp-hackers mailing list