|
665 |
|
665 |
|
666 |
header.SetFlags (flags); |
666 |
header.SetFlags (flags); |
667 |
header.SetSequenceNumber (m_nextTxSequence); |
667 |
header.SetSequenceNumber (m_nextTxSequence); |
668 |
header.SetAckNumber (m_nextRxSequence); |
668 |
header.SetAckNumber (flags & TcpHeader::ACK ? m_nextRxSequence : SequenceNumber (0)); |
669 |
header.SetSourcePort (m_endPoint->GetLocalPort ()); |
669 |
header.SetSourcePort (m_endPoint->GetLocalPort ()); |
670 |
header.SetDestinationPort (m_remotePort); |
670 |
header.SetDestinationPort (m_remotePort); |
671 |
header.SetWindowSize (AdvertisedWindowSize()); |
671 |
header.SetWindowSize (AdvertisedWindowSize()); |
|
1001 |
TcpHeader header; |
1001 |
TcpHeader header; |
1002 |
header.SetFlags (flags); |
1002 |
header.SetFlags (flags); |
1003 |
header.SetSequenceNumber (m_nextTxSequence); |
1003 |
header.SetSequenceNumber (m_nextTxSequence); |
1004 |
header.SetAckNumber (m_nextRxSequence); |
1004 |
header.SetAckNumber (withAck ? m_nextRxSequence : SequenceNumber (0)); |
1005 |
header.SetSourcePort (m_endPoint->GetLocalPort()); |
1005 |
header.SetSourcePort (m_endPoint->GetLocalPort()); |
1006 |
header.SetDestinationPort (m_remotePort); |
1006 |
header.SetDestinationPort (m_remotePort); |
1007 |
header.SetWindowSize (AdvertisedWindowSize()); |
1007 |
header.SetWindowSize (AdvertisedWindowSize()); |