X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/abc8c2d61c65757011d9d32abb01cd1e51232f3a..b51a0dafc7861eb31d21524ec067d7c529a664b8:/print-nfs.c?ds=sidebyside diff --git a/print-nfs.c b/print-nfs.c index a7218f25..20b0cfce 100644 --- a/print-nfs.c +++ b/print-nfs.c @@ -291,7 +291,6 @@ parse_sattr3(netdissect_options *ndo, sa3->sa_atimetype = GET_BE_U_4(dp); dp++; if (sa3->sa_atimetype == NFSV3SATTRTIME_TOCLIENT) { - ND_TCHECK_4(dp + 1); sa3->sa_atime.nfsv3_sec = GET_BE_U_4(dp); dp++; sa3->sa_atime.nfsv3_nsec = GET_BE_U_4(dp); @@ -301,7 +300,6 @@ parse_sattr3(netdissect_options *ndo, sa3->sa_mtimetype = GET_BE_U_4(dp); dp++; if (sa3->sa_mtimetype == NFSV3SATTRTIME_TOCLIENT) { - ND_TCHECK_4(dp + 1); sa3->sa_mtime.nfsv3_sec = GET_BE_U_4(dp); dp++; sa3->sa_mtime.nfsv3_nsec = GET_BE_U_4(dp); @@ -309,8 +307,6 @@ parse_sattr3(netdissect_options *ndo, } return dp; -trunc: - return NULL; } static void @@ -344,7 +340,6 @@ nfsreply_print(netdissect_options *ndo, ndo->ndo_protocol = "nfs"; rp = (const struct sunrpc_msg *)bp; - ND_TCHECK_4(rp->rm_xid); if (!ndo->ndo_nflag) { strlcpy(srcid, "nfs", sizeof(srcid)); snprintf(dstid, sizeof(dstid), "%u", @@ -357,10 +352,6 @@ nfsreply_print(netdissect_options *ndo, print_nfsaddr(ndo, bp2, srcid, dstid); nfsreply_noaddr_print(ndo, bp, length, bp2); - return; - -trunc: - nd_print_trunc(ndo); } void @@ -1321,15 +1312,12 @@ parserddires(netdissect_options *ndo, if (ndo->ndo_qflag) return (1); - ND_TCHECK_4(dp + 2); ND_PRINT(" offset 0x%x size %u ", GET_BE_U_4(dp), GET_BE_U_4(dp + 1)); if (GET_BE_U_4(dp + 2) != 0) ND_PRINT(" eof"); return (1); -trunc: - return (0); } static const uint32_t *