use a appropriate naming for structure fields.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21016 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1120,8 +1120,8 @@ TCPEndpoint::_SendQueued(bool force, uint32 sendWindow)
|
|||||||
if ((fOptions & TCP_NOOPT) == 0) {
|
if ((fOptions & TCP_NOOPT) == 0) {
|
||||||
if (fFlags & FLAG_OPTION_TIMESTAMP) {
|
if (fFlags & FLAG_OPTION_TIMESTAMP) {
|
||||||
segment.options |= TCP_HAS_TIMESTAMPS;
|
segment.options |= TCP_HAS_TIMESTAMPS;
|
||||||
segment.TimestampReply = fReceivedTimestamp;
|
segment.timestamp_reply = fReceivedTimestamp;
|
||||||
segment.TimestampValue = tcp_now();
|
segment.timestamp_value = tcp_now();
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((segment.flags & TCP_FLAG_SYNCHRONIZE)
|
if ((segment.flags & TCP_FLAG_SYNCHRONIZE)
|
||||||
@@ -1579,7 +1579,7 @@ TCPEndpoint::_UpdateTimestamps(tcp_segment_header &segment,
|
|||||||
|
|
||||||
if ((fLastAcknowledgeSent >= sequence
|
if ((fLastAcknowledgeSent >= sequence
|
||||||
&& fLastAcknowledgeSent < (sequence + segmentLength)))
|
&& fLastAcknowledgeSent < (sequence + segmentLength)))
|
||||||
fReceivedTimestamp = segment.TimestampValue;
|
fReceivedTimestamp = segment.timestamp_value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1650,7 +1650,7 @@ TCPEndpoint::_PrepareReceivePath(tcp_segment_header &segment)
|
|||||||
|
|
||||||
if (segment.options & TCP_HAS_TIMESTAMPS) {
|
if (segment.options & TCP_HAS_TIMESTAMPS) {
|
||||||
fFlags |= FLAG_OPTION_TIMESTAMP;
|
fFlags |= FLAG_OPTION_TIMESTAMP;
|
||||||
fReceivedTimestamp = segment.TimestampValue;
|
fReceivedTimestamp = segment.timestamp_value;
|
||||||
} else
|
} else
|
||||||
fFlags &= ~FLAG_OPTION_TIMESTAMP;
|
fFlags &= ~FLAG_OPTION_TIMESTAMP;
|
||||||
}
|
}
|
||||||
@@ -1715,7 +1715,7 @@ TCPEndpoint::_Acknowledged(tcp_segment_header &segment)
|
|||||||
// this ACK acknowledged data
|
// this ACK acknowledged data
|
||||||
|
|
||||||
if (segment.options & TCP_HAS_TIMESTAMPS)
|
if (segment.options & TCP_HAS_TIMESTAMPS)
|
||||||
_UpdateSRTT(tcp_diff_timestamp(segment.TimestampReply));
|
_UpdateSRTT(tcp_diff_timestamp(segment.timestamp_reply));
|
||||||
else {
|
else {
|
||||||
// TODO Fallback to RFC 793 type estimation
|
// TODO Fallback to RFC 793 type estimation
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -134,9 +134,9 @@ add_options(tcp_segment_header &segment, uint8 *buffer, size_t bufferSize)
|
|||||||
bump_option(option, length);
|
bump_option(option, length);
|
||||||
option->kind = TCP_OPTION_TIMESTAMP;
|
option->kind = TCP_OPTION_TIMESTAMP;
|
||||||
option->length = 10;
|
option->length = 10;
|
||||||
option->timestamp.TimestampValue = htonl(segment.TimestampValue);
|
option->timestamp.timestamp_value = htonl(segment.timestamp_value);
|
||||||
// TSecr is opaque to us, we send it as we received it.
|
// TSecr is opaque to us, we send it as we received it.
|
||||||
option->timestamp.TimestampReply = segment.TimestampReply;
|
option->timestamp.timestamp_reply = segment.timestamp_reply;
|
||||||
bump_option(option, length);
|
bump_option(option, length);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -307,9 +307,9 @@ process_options(tcp_segment_header &segment, net_buffer *buffer, size_t size)
|
|||||||
case TCP_OPTION_TIMESTAMP:
|
case TCP_OPTION_TIMESTAMP:
|
||||||
if (option->length == 10 && (size - 10) >= 0) {
|
if (option->length == 10 && (size - 10) >= 0) {
|
||||||
segment.options |= TCP_HAS_TIMESTAMPS;
|
segment.options |= TCP_HAS_TIMESTAMPS;
|
||||||
segment.TimestampValue = option->timestamp.TimestampValue;
|
segment.timestamp_value = option->timestamp.timestamp_value;
|
||||||
segment.TimestampReply =
|
segment.timestamp_reply =
|
||||||
ntohl(option->timestamp.TimestampReply);
|
ntohl(option->timestamp.timestamp_reply);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case TCP_OPTION_SACK_PERMITTED:
|
case TCP_OPTION_SACK_PERMITTED:
|
||||||
|
|||||||
@@ -118,8 +118,8 @@ struct tcp_option {
|
|||||||
uint8 window_shift;
|
uint8 window_shift;
|
||||||
uint16 max_segment_size;
|
uint16 max_segment_size;
|
||||||
struct {
|
struct {
|
||||||
uint32 TimestampValue;
|
uint32 timestamp_value;
|
||||||
uint32 TimestampReply;
|
uint32 timestamp_reply;
|
||||||
} timestamp;
|
} timestamp;
|
||||||
tcp_sack sack[0];
|
tcp_sack sack[0];
|
||||||
};
|
};
|
||||||
@@ -161,8 +161,8 @@ struct tcp_segment_header {
|
|||||||
uint8 window_shift;
|
uint8 window_shift;
|
||||||
uint16 max_segment_size;
|
uint16 max_segment_size;
|
||||||
|
|
||||||
uint32 TimestampValue;
|
uint32 timestamp_value;
|
||||||
uint32 TimestampReply;
|
uint32 timestamp_reply;
|
||||||
|
|
||||||
tcp_sack *sacks;
|
tcp_sack *sacks;
|
||||||
int sack_count;
|
int sack_count;
|
||||||
|
|||||||
Reference in New Issue
Block a user