From: plugwash Date: Fri, 12 Feb 2010 22:26:21 +0000 (+0000) Subject: add some missing ifdefs X-Git-Url: http://www.lcore.org/git/lcore.git/commitdiff_plain/931a750a50f8191665d56c1ec341f6892f1f026c add some missing ifdefs git-svn-id: file:///svnroot/lcore/trunk@76 b1de8a11-f9be-4011-bde0-cc7ace90066a --- 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};