[#CreateSockOS]
= CreateSockOS
:mrdocs:

Create a real socket from the operating system&period;

== Synopsis

Declared in `&lt;netbase&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
std::unique&lowbar;ptr&lt;Sock&gt;
CreateSockOS(
    int domain,
    int type,
    int protocol);
----

== Return Value

pointer to the created Sock object or unique&lowbar;ptr that owns nothing in case of failure

== Parameters

[cols="1,4"]
|===
| Name| Description
| *domain* [in]
| Communications domain, first argument to the socket(2) syscall&period;
| *type* [in]
| Type of the socket, second argument to the socket(2) syscall&period;
| *protocol* [in]
| The particular protocol to be used with the socket, third argument to the socket(2) syscall&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
