From c47037b066169c61c5eefad3368f2da73ca4be54 Mon Sep 17 00:00:00 2001 From: aaron <> Date: Mon, 5 Jul 1999 04:41:00 +0000 Subject: repairs; better English, formatting, etc. --- src/lib/libc/net/ethers.3 | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) (limited to 'src/lib/libc/net/ethers.3') diff --git a/src/lib/libc/net/ethers.3 b/src/lib/libc/net/ethers.3 index 74d153fce6..39968f3e65 100644 --- a/src/lib/libc/net/ethers.3 +++ b/src/lib/libc/net/ethers.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: ethers.3,v 1.10 1999/03/18 11:09:15 aaron Exp $ +.\" $OpenBSD: ethers.3,v 1.11 1999/07/05 04:40:59 aaron Exp $ .\" .\" Written by roland@frob.com. Public domain. .\" @@ -26,7 +26,7 @@ .Ft int .Fn ether_line "char *l" "struct ether_addr *e" "char *hostname" .Sh DESCRIPTION -Ethernet addresses are represented by the +Ethernet addresses are represented by the following structure: .Bd -literal -offset indent struct ether_addr { @@ -36,13 +36,18 @@ struct ether_addr { .Pp The .Fn ether_ntoa -function converts this structure into an ASCII string of the form -``xx:xx:xx:xx:xx:xx'', consisting of 6 hexadecimal numbers separated +function converts this structure into an +.Tn ASCII +string of the form +.Dq xx:xx:xx:xx:xx:xx , +consisting of 6 hexadecimal numbers separated by colons. It returns a pointer to a static buffer that is reused for each call. The .Fn ether_aton -converts an ASCII string of the same form and to a structure +converts an +.Tn ASCII +string of the same form and to a structure containing the 6 octets of the address. It returns a pointer to a static structure that is reused for each call. .Pp @@ -57,17 +62,19 @@ The .Fn ether_ntohost function looks up the given Ethernet address and writes the associated host name into the character buffer passed. This buffer should be -.Ev MAXHOSTNAMELEN +.Dv MAXHOSTNAMELEN characters in size. The .Fn ether_hostton function looks up the given host name and writes the associated Ethernet address into the structure passed. Both functions return -zero if they find the requested host name or address, and -1 if not. +zero if they find the requested host name or address, and \-1 if not. .Pp Each call reads -.Pa /etc/ethers -from the beginning; if a + appears alone on a line in the file, then +.Pa /etc/ethers +from the beginning; if a +.Ql + +appears alone on a line in the file, then .Fn ether_hostton will consult the .Pa ethers.byname @@ -81,11 +88,12 @@ The .Fn ether_line function parses a line from the .Pa /etc/ethers -file and fills in the passed ``struct ether_addr'' and character -buffer with the Ethernet address and host name on the line. It -returns zero if the line was successfully parsed and -1 if not. +file and fills in the passed +.Li struct ether_addr +and character buffer with the Ethernet address and host name on the line. It +returns zero if the line was successfully parsed and \-1 if not. The character buffer should be -.Ev MAXHOSTNAMELEN +.Dv MAXHOSTNAMELEN characters in size. .Sh FILES .Bl -tag -width /etc/ethers -compact -- cgit v1.2.3-55-g6feb