updated network stack interface address check handling in ios/osx

This commit is contained in:
Joseph Henry
2016-10-24 17:48:01 -07:00
parent 3df5034d5a
commit 925882b8c0
5 changed files with 38 additions and 29 deletions

View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15G1004" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>

View File

@@ -183,12 +183,11 @@ class ViewController: UIViewController {
while(true)
{
sleep(1)
dispatch_async(dispatch_get_main_queue()) {
//var str_buf = [Int8](count: 16, repeatedValue: 0)
//print(self.zt.get_address(self.txtNWID.text!)) //, &str_buf);
//self.lblAddress.text = String.fromCString(str_buf)
// print("IPV4 = ", String.fromCString(str_buf))
var str_buf = [Int8](count: 16, repeatedValue: 0)
self.zt.get_ipv6_address(self.txtNWID.text!, &str_buf)
self.lblAddress.text = String.fromCString(str_buf)
print("addr = ", String.fromCString(str_buf))
}