diff options
author | Denis Ovsienko <denis@ovsienko.info> | 2017-09-13 13:26:02 +0100 |
---|---|---|
committer | Denis Ovsienko <denis@ovsienko.info> | 2017-09-13 13:33:02 +0100 |
commit | 413840cf188d748819f718655db02e8927d590b0 (patch) | |
tree | 52e7fe2042329a9978ea02f8967b85185f49b079 /print-ldp.c | |
parent | e5ab6e7001ce66740193be7db47b462a944ada10 (diff) | |
download | tcpdump-413840cf188d748819f718655db02e8927d590b0.tar.gz |
Don't specify struct as "const" within sizeof().
The only difference the const qualifier makes in this context is visual,
make it consistent with the rest of the source code.
Diffstat (limited to 'print-ldp.c')
-rw-r--r-- | print-ldp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/print-ldp.c b/print-ldp.c index 2a3d1f97..d556a683 100644 --- a/print-ldp.c +++ b/print-ldp.c @@ -581,12 +581,12 @@ ldp_pdu_print(netdissect_options *ndo, } pdu_len = EXTRACT_16BITS(&ldp_com_header->pdu_length); - if (pdu_len < sizeof(const struct ldp_common_header)-4) { + if (pdu_len < sizeof(struct ldp_common_header)-4) { /* length too short */ ND_PRINT((ndo, "%sLDP, pdu-length: %u (too short, < %u)", (ndo->ndo_vflag < 1) ? "" : "\n\t", pdu_len, - (u_int)(sizeof(const struct ldp_common_header)-4))); + (u_int)(sizeof(struct ldp_common_header)-4))); return 0; } @@ -602,8 +602,8 @@ ldp_pdu_print(netdissect_options *ndo, return 0; /* ok they seem to want to know everything - lets fully decode it */ - tptr = pptr + sizeof(const struct ldp_common_header); - tlen = pdu_len - (sizeof(const struct ldp_common_header)-4); /* Type & Length fields not included */ + tptr = pptr + sizeof(struct ldp_common_header); + tlen = pdu_len - (sizeof(struct ldp_common_header)-4); /* Type & Length fields not included */ while(tlen>0) { /* did we capture enough for fully decoding the msg header ? */ |