closesocket(hsocket);
}
char Dest[3000];
nRet=1;
while(nRet>0)
{
// 接收返回数据包
nRet=recv(hsocket,(LPSTR)Dest,sizeof(Dest),0);
printf("nRet is:%d\n");
if(nRet>0)
Dest[nRet]=0;
else
Dest[0]=0;
// 显示返回数据包的大小、内容
printf("\nReceived bytes:%d\n",nRet);
printf("Result:\n%s",Dest);
}
return 0;
}
"Connection: Keep-Alive\r\n"
"Cookie: JSESSIONID=A55DFDF6FE50070D841925B49D425BB2\r\n";
改成
"Connection: Close\r\n"
"Cookie: JSESSIONID=A55DFDF6FE50070D841925B49D425BB2\r\n\r\n";
上一页 [1] [2]