From ffb395eb93c110078022f8686ce8df1b35f68db9 Mon Sep 17 00:00:00 2001 From: ngie Date: Tue, 28 Mar 2017 06:13:16 +0000 Subject: [PATCH] MFC r313436,r313437,r313438,r314587,r315687: r313436: Clarify #includes for hexdump(3) vs sbuf_hexdump(9) hexdump(3) only requires libutil.h, whereas sbuf_hexdump(9) requires sys/types.h (for ssize_t) and sys/sbuf.h r313437: Create link from hexdump(3) to sbuf_hexdump(9) as the manpage describes sbuf_hexdump(9)'s behavior r313438: Clean up trailing and leading whitespace for variables to make it consistent with the rest of the file and style.Makefile(9) a bit more r314587: Correct MLINKS for sbuf_hexdump(9) sbuf_hexdump(9) should be linked to sbuf(9), not hexdump(3). Another review will be posted to deduplicate the sbuf_hexdump reference in in hexdump(3) or at the very least make the information less duplicative. r315687: Document sbuf_hexdump(9) in just sbuf(9) - Remove duplicate references to sbuf_hexdump(9) from hexdump(3). sbuf_hexdump(9) already pointed back to hexdump(3) for implementation details. - Refer to sbuf_hexdump(9) instead of sbuf(9) for completeness git-svn-id: svn://svn.freebsd.org/base/stable/10@316074 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f --- lib/libutil/hexdump.3 | 18 ++---------------- share/man/man9/Makefile | 1 + 2 files changed, 3 insertions(+), 16 deletions(-) diff --git a/lib/libutil/hexdump.3 b/lib/libutil/hexdump.3 index 9fa96f899..76db9894d 100644 --- a/lib/libutil/hexdump.3 +++ b/lib/libutil/hexdump.3 @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 8, 2014 +.Dd March 21, 2017 .Dt HEXDUMP 3 .Os .Sh NAME @@ -36,17 +36,8 @@ .Nd "dump a block of bytes to standard out in hexadecimal form" .Sh SYNOPSIS .In libutil.h -.In sys/sbuf.h .Ft void .Fn hexdump "void *ptr" "int length" "const char *hdr" "int flags" -.Ft void -.Fo sbuf_hexdump -.Fa "struct sbuf *sb" -.Fa "void *ptr" -.Fa "int length" -.Fa "const char *hdr" -.Fa "int flags" -.Fc .Sh DESCRIPTION The .Fn hexdump @@ -59,11 +50,6 @@ output will start with an offset count, followed by 16 hexadecimal values, followed by 16 .Tn ASCII characters. -.Pp -The -.Fn sbuf_hexdump -function prints the hexdump to the supplied -.Xr sbuf 9 . .Bl -tag -width indent .It Fa ptr Pointer to the array of bytes to print. @@ -103,7 +89,7 @@ Do not print the character values on each line. .El .Sh SEE ALSO .Xr ascii 7 , -.Xr sbuf 9 +.Xr sbuf_hexdump 9 .Sh AUTHORS This manual page was written by .An Scott Long . diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index 3a3508aba..9f4a400b0 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -1156,6 +1156,7 @@ MLINKS+=sbuf.9 sbuf_bcat.9 \ sbuf.9 sbuf_done.9 \ sbuf.9 sbuf_error.9 \ sbuf.9 sbuf_finish.9 \ + sbuf.9 sbuf_hexdump.9 \ sbuf.9 sbuf_len.9 \ sbuf.9 sbuf_new.9 \ sbuf.9 sbuf_new_for_sysctl.9 \ -- 2.42.0