test update
This commit is contained in:
@@ -74,11 +74,11 @@
|
|||||||
ignoreCount = "0"
|
ignoreCount = "0"
|
||||||
continueAfterRunningActions = "No"
|
continueAfterRunningActions = "No"
|
||||||
filePath = "Example_OSX_App/ViewController.swift"
|
filePath = "Example_OSX_App/ViewController.swift"
|
||||||
timestampString = "490569101.315649"
|
timestampString = "490569637.32756"
|
||||||
startingColumnNumber = "9223372036854775807"
|
startingColumnNumber = "9223372036854775807"
|
||||||
endingColumnNumber = "9223372036854775807"
|
endingColumnNumber = "9223372036854775807"
|
||||||
startingLineNumber = "181"
|
startingLineNumber = "179"
|
||||||
endingLineNumber = "181"
|
endingLineNumber = "179"
|
||||||
landmarkName = "UI_ReadData(_:)"
|
landmarkName = "UI_ReadData(_:)"
|
||||||
landmarkType = "5">
|
landmarkType = "5">
|
||||||
</BreakpointContent>
|
</BreakpointContent>
|
||||||
@@ -102,15 +102,15 @@
|
|||||||
<BreakpointProxy
|
<BreakpointProxy
|
||||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||||
<BreakpointContent
|
<BreakpointContent
|
||||||
shouldBeEnabled = "Yes"
|
shouldBeEnabled = "No"
|
||||||
ignoreCount = "0"
|
ignoreCount = "0"
|
||||||
continueAfterRunningActions = "No"
|
continueAfterRunningActions = "No"
|
||||||
filePath = "Example_OSX_App/ViewController.swift"
|
filePath = "Example_OSX_App/ViewController.swift"
|
||||||
timestampString = "490569259.570714"
|
timestampString = "490569637.32756"
|
||||||
startingColumnNumber = "9223372036854775807"
|
startingColumnNumber = "9223372036854775807"
|
||||||
endingColumnNumber = "9223372036854775807"
|
endingColumnNumber = "9223372036854775807"
|
||||||
startingLineNumber = "180"
|
startingLineNumber = "178"
|
||||||
endingLineNumber = "180"
|
endingLineNumber = "178"
|
||||||
landmarkName = "UI_ReadData(_:)"
|
landmarkName = "UI_ReadData(_:)"
|
||||||
landmarkType = "5">
|
landmarkType = "5">
|
||||||
</BreakpointContent>
|
</BreakpointContent>
|
||||||
|
|||||||
@@ -174,7 +174,7 @@ class ViewController: NSViewController {
|
|||||||
//let str = "Welcome to the machine"
|
//let str = "Welcome to the machine"
|
||||||
print("strlen = %d\n", str.characters.count)
|
print("strlen = %d\n", str.characters.count)
|
||||||
let encodedDataArray = [UInt8](str.utf8)
|
let encodedDataArray = [UInt8](str.utf8)
|
||||||
read(accepted_sock, &buffer, 4);
|
read(accepted_sock, &buffer, 1024);
|
||||||
print(buffer)
|
print(buffer)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,26 +34,15 @@ int main(int argc , char *argv[])
|
|||||||
}
|
}
|
||||||
printf("connected\n");
|
printf("connected\n");
|
||||||
|
|
||||||
while(1) {
|
char *msg = "welcome to the machine!";
|
||||||
printf("enter message : ");
|
// TX
|
||||||
scanf("%s" , message);
|
if(send(sock, msg, strlen(msg), 0) < 0) {
|
||||||
|
printf("send failed");
|
||||||
// TX
|
return 1;
|
||||||
if(send(sock, message, strlen(message), 0) < 0) {
|
}
|
||||||
printf("send failed");
|
else {
|
||||||
return 1;
|
printf("sent message: %s\n", msg);
|
||||||
}
|
printf("len = %ld\n", strlen(msg));
|
||||||
else {
|
|
||||||
printf("len = %ld\n", strlen(message));
|
|
||||||
}
|
|
||||||
|
|
||||||
// RX
|
|
||||||
if(recv(sock , server_reply , 2000 , 0) < 0) {
|
|
||||||
printf("recv failed");
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
printf("server reply :");
|
|
||||||
puts(server_reply);
|
|
||||||
}
|
}
|
||||||
close(sock);
|
close(sock);
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user