   i already int it BUT why error c2065?
  void CTcpSock::setKeepAlive( bool keepAlive ){nlassert(_Sock != INVALID_SOCKET)int b = keepAlive?1:0;the wrong with here: cant find "b"if ( setsockopt( _Sock, SOL_SOCKET, SO_KEEPALIVE, (char*)&b, sizeof(b) ) != 0 ){throw ESocket( "setKeepAlive failed" );}}   
  You most likely need to end the previous line (nlassert(...)) with a semicolon (;). I'm not sure that's the problem, but it could be, especially if nlassert is a macro.Also could you show us the code all the way down to that if statement? Is it right after declaring b?   ;  wow!! you right~  it is work now  so thank you~i got that code from  Nel library  http://www.nevrax.org/but that website always stop run at recently~if you want the code  i could send to you by mail   