netconn_type() — Obtain the type of netconn


enum netconn_type netconn_type (struct netconn *conn );


Returns the type of the connection conn. This is the same type that is given as an argument to netconn_new() (and its variants) and can be one of NETCONN_TCP, NETCONN_UDP, NETCONN_UDPLITE, NETCONN_UDPNOCHKSUM or NETCONN_RAW.

If IPv6 support is configured then it can also be one of NETCONN_TCP_IPV6, NETCONN_UDP_IPV6, NETCONN_UDPLITE_IPV6 or NETCONN_UDPNOCHKSUM_IPV6.