iPv6对应用程序的支持(目标-c) [英] iPv6 support for Application (objective-c)

查看:105
本文介绍了iPv6对应用程序的支持(目标-c)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Apple在其文档中提到要删除一些支持iPV6的API. 我们在应用程序中使用下面的API.

Apple has mentioned in their document to eliminate some API for iPV6 support. We are using below API in our application.

inet_ntoa()   
inet_aton()

除了上述API以外,是否还有其他API可同时支持IPv4和IPv6?

Is there any other API instead of above API for support both IPv4 & IPv6?

推荐答案

inet_ntoa(3N)解释IPv4互联网地址并将其转换为字符串. 代替inetntoa函数,我使用了inet_ntop(3N)函数. 此功能对IPv4和IPv6地址执行相同的操作

inet_ntoa(3N) interprets an IPv4 internet address and converts it to a character string. instead of inetntoa function i used inet_ntop(3N) function. This function perform the same operation for both IPv4 and IPv6 addresses

下面的链接帮助我在很多方面为我的应用程序支持iPv6. http://uw714doc.sco.com/en/SDK_netapi/sockC.PortIPv4appIPv6.html

这篇关于iPv6对应用程序的支持(目标-c)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆