查找C / C可用的网络接口++ [英] Find available network interfaces in c/c++
本文介绍了查找C / C可用的网络接口++的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有谁知道一个C / C ++ code代表
寻找网络接口可用?
我一直在寻找一些codeS,但大多数时候the're相当复杂。有一个简单的方法来做到这一点?
Does anyone know a c/c++ code for finding the network interfaces available? I've been looking for some codes, but most times the're quite complex. Is there a simple way to do this?
更新
在Ubuntu / Linux的
On Ubuntu/Linux
推荐答案
查看的 getifaddrs 手册页。有接近尾声的示例程序。
See the getifaddrs man page. There is an example program towards the end.
这篇关于查找C / C可用的网络接口++的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文