diff options
author | Guy Harris <guy@alum.mit.edu> | 2018-12-26 18:26:24 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2018-12-27 04:34:29 +0000 |
commit | 7eb3e47fa49806ea2cf59f0fa009240fae049a2b (patch) | |
tree | d668ff9ceae57934fe33582457fc5169f6e764ba /epan/dissectors/packet-ncp2222.inc | |
parent | c3a7986b86f5355e6bd1791f70b78c91bcdac247 (diff) |
Try to squeeze some bytes out of the frame_data structure.
Make the time stamp precision a 4-bit bitfield, so, when combined with
the other bitfields, we have 32 bits. That means we put the flags at
the same structure level as the time stamp precision, so they can be
combined; that gets rid of an extra "flags." for references to the flags.
Put the two pointers next to each other, and after a multiple of 8 bytes
worth of other fields, so that there's no padding before or between them.
It's still not down to 64 bytes, which is the next lower power of 2, so
there's more work to do.
Change-Id: I6f3e9d9f6f48137bbee8f100c152d2c42adb8fbe
Reviewed-on: https://code.wireshark.org/review/31213
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-ncp2222.inc')
-rw-r--r-- | epan/dissectors/packet-ncp2222.inc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/epan/dissectors/packet-ncp2222.inc b/epan/dissectors/packet-ncp2222.inc index 3c1938e6c9..1662a41ac6 100644 --- a/epan/dissectors/packet-ncp2222.inc +++ b/epan/dissectors/packet-ncp2222.inc @@ -6720,7 +6720,7 @@ nds_defrag(tvbuff_t *tvb, packet_info *pinfo, guint32 nw_connection, guint8 sequ return; } /* Has this already been dissected? */ - if (!pinfo->fd->flags.visited) { + if (!pinfo->fd->visited) { /* Find the conversation whence the request would have come. */ conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_NCP, nw_connection, nw_connection, 0); @@ -6831,7 +6831,7 @@ nds_defrag(tvbuff_t *tvb, packet_info *pinfo, guint32 nw_connection, guint8 sequ /* Subsequent fragments should be offset by 16 since we do not need */ /* the additional fragment handle and size fields in our composite data */ /* Also do not add retransmitted packets, just mark and return */ - if (!pinfo->fd->flags.visited) + if (!pinfo->fd->visited) { if (sequence != frags[frag_count].sequence) { fd_head = fragment_add_seq_next(&nds_reassembly_table, tvb, 16, pinfo, tid, NULL, len-16, request_value->nds_frag); @@ -6869,7 +6869,7 @@ nds_defrag(tvbuff_t *tvb, packet_info *pinfo, guint32 nw_connection, guint8 sequ tid++; } - if (!pinfo->fd->flags.visited) + if (!pinfo->fd->visited) { /* Now we need to find the original fragment number. */ /* Get the fragment flag */ @@ -7087,7 +7087,7 @@ dissect_ncp_request(tvbuff_t *tvb, packet_info *pinfo, } } - if (!pinfo->fd->flags.visited) { + if (!pinfo->fd->visited) { /* This is the first time we've looked at this packet. Keep track of the address and connection whence the request came, and the address and connection to which the request @@ -7864,7 +7864,7 @@ dissect_nds_reply(tvbuff_t *tvb, packet_info *pinfo, * this EID and its associated name into our hash * so that we can resolve the name for other NDS * requests. */ - if (!pinfo->fd->flags.visited) { + if (!pinfo->fd->visited) { if(add_eid) { request_eid_value = ncp_eid_hash_lookup(conversation, global_eid); @@ -7924,7 +7924,7 @@ dissect_ncp_reply(tvbuff_t *tvb, packet_info *pinfo, } #endif - if (!pinfo->fd->flags.visited) { + if (!pinfo->fd->visited) { /* Find the conversation whence the request would have come. */ conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_NCP, nw_connection, nw_connection, 0); @@ -8258,7 +8258,7 @@ dissect_nds_request(tvbuff_t *tvb, packet_info *pinfo, ENDPOINT_NCP, nw_connection, nw_connection, 0); } - if (!pinfo->fd->flags.visited) { + if (!pinfo->fd->visited) { request_value = ncp_hash_insert(conversation, sequence, ncp_rec, pinfo->num); request_value->req_frame_num = pinfo->num; request_value->req_frame_time=pinfo->abs_ts; @@ -9231,7 +9231,7 @@ dissect_ping_req(tvbuff_t *tvb, packet_info *pinfo, col_set_str(pinfo->cinfo, COL_INFO, "C Ping for NDS"); } - if (!pinfo->fd->flags.visited) + if (!pinfo->fd->visited) { /* This is the first time we've looked at this packet. |