Skip to content

please make ntsa::SocketOption::print() output include option type #254

@lxv

Description

@lxv
ntsa::SocketOption so1;
so1.makeLinger();

ntsa::SocketOption so2;
so2.makeZeroCopy();

std::cout << "so1=" << so1 << std::endl;
std::cout << "so2=" << so2 << std::endl;

outputs:

so1=LINGER[ enabled = false duration = (4829128, 21860576) ]
so2=0

If the first line of the output is actually useful to convey the option type and its value, the 2nd line is not so much. I suggest you always include both option type and the value in the string representation of ntsa::SocketOption values.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions