Skip to content

rustix::net::netdevice::index_to_name is returning String #1393

Open
@al8n

Description

@al8n

Hi, on the Linux and BSD platform, the max interface name length is 16, which is small enough to be inlined instead of a heap-allocated String.

If we change the returning type to an inlined array or somehow a wrapper over [u8; 16], we can remove the alloc requirement.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions