|
|
| 121 |
uint32_t |
121 |
uint32_t |
| 122 |
ArpHeader::GetSerializedSize (void) const |
122 |
ArpHeader::GetSerializedSize (void) const |
| 123 |
{ |
123 |
{ |
| 124 |
/* this is the size of an ARP payload. */ |
124 |
NS_ASSERT((m_macSource.GetLength () == 6) || (m_macSource.GetLength () == 8)); |
| 125 |
return 28; |
125 |
NS_ASSERT (m_macSource.GetLength () == m_macDest.GetLength ()); |
|
|
126 |
|
| 127 |
uint32_t length = 16; // Length minus two hardware addresses |
| 128 |
length += m_macSource.GetLength () * 2; |
| 129 |
|
| 130 |
return length; |
| 126 |
} |
131 |
} |
| 127 |
|
132 |
|
| 128 |
void |
133 |
void |