#include <iostream>
#include <cstring>
#include <sys/socket.h>
#include <netinet/in.h>
#include <unistd.h>
#include <arpa/inet.h>
using namespace std;
#define MYPORT 3456 //服务器监听端口号
int main()
{
cout << "客户端已启动~" << endl;
sockaddr_in Server_addr;
int Client_Socket = socket(AF_INET, SOCK_STREAM, 0);
Linux 下 C++ Socket编程 客户端
最新推荐文章于 2025-05-28 13:59:12 发布