summaryrefslogtreecommitdiff
path: root/util-print.c
diff options
context:
space:
mode:
authorFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2020-12-10 22:49:21 +0100
committerFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2020-12-10 22:52:57 +0100
commit2eb023747062b79164c8f34adbf893bec938dd9a (patch)
treeaa9dbaa22a99ba333242215bbfb2e232cc837f4d /util-print.c
parentd9893474ee1284e8772474c26ba0830657d4f33d (diff)
downloadtcpdump-2eb023747062b79164c8f34adbf893bec938dd9a.tar.gz
Remove the no more used nd_printzp() function
The function to use now is: nd_printjnp(). (Added by comit 635e3cc92b72ca048a6b5b89b883980e4e1b4bdc)
Diffstat (limited to 'util-print.c')
-rw-r--r--util-print.c30
1 files changed, 0 insertions, 30 deletions
diff --git a/util-print.c b/util-print.c
index 3d3caa5a..f9ea618d 100644
--- a/util-print.c
+++ b/util-print.c
@@ -199,36 +199,6 @@ nd_printn(netdissect_options *ndo,
}
/*
- * Print out a null-padded filename (or other ASCII string), part of
- * the packet buffer.
- * If ep is NULL, assume no truncation check is needed.
- * Return true if truncated.
- * Stop at ep (if given) or after n bytes or before the null char,
- * whichever is first.
- */
-int
-nd_printzp(netdissect_options *ndo,
- const u_char *s, u_int n,
- const u_char *ep)
-{
- int ret;
- u_char c;
-
- ret = 1; /* assume truncated */
- while (n > 0 && (ep == NULL || s < ep)) {
- n--;
- c = GET_U_1(s);
- s++;
- if (c == '\0') {
- ret = 0;
- break;
- }
- fn_print_char(ndo, c);
- }
- return (n == 0) ? 0 : ret;
-}
-
-/*
* Print a null-padded filename (or other ASCII string), part of
* the packet buffer, filtering out non-printable characters.
* Stop if truncated (via GET_U_1/longjmp) or after n bytes or before