|
674 |
Address fromAddress = InetSocketAddress (saddr, port); |
674 |
Address fromAddress = InetSocketAddress (saddr, port); |
675 |
Address toAddress = InetSocketAddress (daddr, m_endPoint->GetLocalPort()); |
675 |
Address toAddress = InetSocketAddress (daddr, m_endPoint->GetLocalPort()); |
676 |
|
676 |
|
677 |
if (m_shutdownRecv) |
|
|
678 |
{ |
679 |
return; |
680 |
} |
681 |
TcpHeader tcpHeader; |
677 |
TcpHeader tcpHeader; |
682 |
packet->RemoveHeader (tcpHeader); |
678 |
packet->RemoveHeader (tcpHeader); |
683 |
|
679 |
|
|
735 |
if (saveState < CLOSING && (m_state == CLOSING || m_state == TIMED_WAIT) ) |
731 |
if (saveState < CLOSING && (m_state == CLOSING || m_state == TIMED_WAIT) ) |
736 |
{ |
732 |
{ |
737 |
NS_LOG_LOGIC ("TcpSocketImpl peer closing, send EOF to application"); |
733 |
NS_LOG_LOGIC ("TcpSocketImpl peer closing, send EOF to application"); |
738 |
NotifyDataRecv (); |
734 |
if (!m_shutdownRecv) |
|
|
735 |
{ |
736 |
NotifyDataRecv (); |
737 |
} |
739 |
} |
738 |
} |
740 |
|
739 |
|
741 |
if (needCloseNotify && !m_closeNotified) |
740 |
if (needCloseNotify && !m_closeNotified) |
|
1296 |
m_rxAvailable += p->GetSize (); |
1295 |
m_rxAvailable += p->GetSize (); |
1297 |
RxBufFinishInsert (tcpHeader.GetSequenceNumber ()); |
1296 |
RxBufFinishInsert (tcpHeader.GetSequenceNumber ()); |
1298 |
m_rxBufSize += p->GetSize (); |
1297 |
m_rxBufSize += p->GetSize (); |
1299 |
NotifyDataRecv (); |
1298 |
if (!m_shutdownRecv) |
|
|
1299 |
{ |
1300 |
NotifyDataRecv (); |
1301 |
} |
1300 |
if (m_closeNotified) |
1302 |
if (m_closeNotified) |
1301 |
{ |
1303 |
{ |
1302 |
NS_LOG_LOGIC ("Tcp " << this << " HuH? Got data after closeNotif"); |
1304 |
NS_LOG_LOGIC ("Tcp " << this << " HuH? Got data after closeNotif"); |
|
1392 |
m_rxAvailable += p->GetSize (); |
1394 |
m_rxAvailable += p->GetSize (); |
1393 |
m_rxBufSize += p->GetSize(); |
1395 |
m_rxBufSize += p->GetSize(); |
1394 |
RxBufFinishInsert(start); |
1396 |
RxBufFinishInsert(start); |
1395 |
NotifyDataRecv (); |
1397 |
if (!m_shutdownRecv) |
|
|
1398 |
{ |
1399 |
NotifyDataRecv (); |
1400 |
} |
1396 |
} |
1401 |
} |
1397 |
else |
1402 |
else |
1398 |
{ // debug |
1403 |
{ // debug |