Skip to content
/ cmsg-rs Public

Helper for working with Unix Domain Socket ancilliary control messages.

License

Notifications You must be signed in to change notification settings

djg/cmsg-rs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cmsg

Build Status

A library for working with ancilliary control messages for Unix Domain Sockets as described by cmsg.

# Cargo.toml
[dependencies]
bytes = "0.4"
cmsg = "0.1"

Usage

To process received control messages, cmsg::iterator() is used to create an iterator adapter over the raw bytes received from libc::recvmsg.

To create control messages, cmsg::builder() is used to create a builder interface over the top of pre-allocated storage. Using Vec<u8>, bytes::BytesMut, and stack-based arrays, via std::io::Cursor are supported. The builder checks that the storages is correctly aligned and maintains alignment of each appended message.

License

cmsg-rs is primarily distributed under the terms of the MIT license.

See LICENSE-MIT for details.

About

Helper for working with Unix Domain Socket ancilliary control messages.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages