libs/stream_message/src/aconnectn.cxx
// ===========================================================================
// code taken from dish/src/SocketComm.C
//
// returns <=0 in case of failure; 1 in case of success
//
code taken from dish/src/SocketComm.C
returns <=0 in case of failure; 1 in case of success
code taken from dish / src / SocketComm . C returns < = 0 in case of failure ; 1 in case of success
int nTransport::send(int socket, char *ptr, int len)
{
    while(len != 0){
	int res = ::send(socket, ptr, len, 0);
	if(res <= 0)
	    return res;
	ptr += res;
	len -= res;
    }
    return 1;
}
int nTransport :: send ( int socket , char * ptr , int len ) { while ( len != 0 ) { int res = :: send ( socket , ptr , len , 0 ) ; if ( res <= 0 ) return res ; ptr += res ; len -= res ; } return 1 ; }
code taken from dish/src/SocketComm.C
returns <=0 in case of failure; 1 in case of success
code taken from dish / src / SocketComm . C returns < = 0 in case of failure ; 1 in case of success