云
云里雾里
Unregistered / Unconfirmed
GUEST, unregistred user!
var
SockAddr: TSockAddr;
AddrLen: integer;
begin
......
FAccept := Accept(FListen, nil, nil); //使用Delphi封装的winsock its OK
FAccept := Accept(FListen, @SockAddr, AddrLen);//使用winsock2 error=10014
end;
下载的winsock2.pas里面accept定义如下:
// Using "var addr:TSockAddr" in accept makes impossible to compile for IPv6
function accept(s: TSocket; addr: PSockAddr; var addrlen: Integer): TSocket; stdcall;
是不是这里定义错了啊?
SockAddr: TSockAddr;
AddrLen: integer;
begin
......
FAccept := Accept(FListen, nil, nil); //使用Delphi封装的winsock its OK
FAccept := Accept(FListen, @SockAddr, AddrLen);//使用winsock2 error=10014
end;
下载的winsock2.pas里面accept定义如下:
// Using "var addr:TSockAddr" in accept makes impossible to compile for IPv6
function accept(s: TSocket; addr: PSockAddr; var addrlen: Integer): TSocket; stdcall;
是不是这里定义错了啊?