In what follows,
ty
denotes the socket type and is of type sockbuf::type
proto
denotes the protocol number and is of type int
su
is a sockbuf
and must be in unix domain
path
is the unix path name like "\socket\unix_socket"
sd
is an integer which is a socket descriptor
sockunixbuf uns(ty, proto)
sockunixbuf
object uns
with ty
as its
type and proto
as its protocol number. proto
defaults to
0.
sockunixbuf uns(sd)
sockunixbuf
from an open socket sd
.
uns.open(ty, proto)
sockunixbuf
object with ty
as its type and
proto
as its protocol and assign the sockunixbuf
object so
created to *this
. It returns this
. proto
defaults
to 0.
uns.bind(path)
uns
to the unix pathname path
.
It returns 0 on success and returns the errno on failure.
uns.connect(path)
uns
to the unix pathname path
.
It returns 0 on success and returns the errno on failure.