X-Git-Url: http://www.lcore.org/git/lcore.git/blobdiff_plain/9a44a542cab11c03215fe3c844dde2529a87258d..931a750a50f8191665d56c1ec341f6892f1f026c:/lsocket.pas diff --git a/lsocket.pas b/lsocket.pas index 53205e6..7f61092 100755 --- a/lsocket.pas +++ b/lsocket.pas @@ -132,7 +132,9 @@ type //this one has to be kept public for now because lcorewsaasyncselect calls it procedure connectionfailedhandler(error:word); private - isv6socket : boolean; //identifies if the socket is v6, set by bindsocket + {$ifdef ipv6} + isv6socket : boolean; //identifies if the socket is v6, set by bindsocket + {$endif} procedure taskcallconnectionfailedhandler(wparam,lparam : longint); procedure connecttimeouthandler(sender:tobject); @@ -352,7 +354,9 @@ begin end; //gethostbyname(localaddr,host); inaddrtempsize := makeinaddrv(forwardlookup(localaddr,0),localport,inaddrtemp); - isv6socket := (inaddrtemp.inaddr.family = AF_INET6); + {$ifdef ipv6} + isv6socket := (inaddrtemp.inaddr.family = AF_INET6); + {$endif} If Bind(fdhandlein,inaddrtempx,inaddrtempsize)<> {$ifdef win32}0{$else}true{$endif} Then begin state := wsclosed; lasterror := {$ifdef win32}getlasterror{$else}socketerror{$endif};