thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gianni Ambrosio <gianni.ambro...@vi-grade.com>
Subject Connection to an empty IP address unexpectedly works
Date Tue, 16 Oct 2018 15:22:53 GMT
Dear All,
in the following code, transport->open() call works fine even if 
ipAddress is an empty string. Why?

boost::shared_ptr<apache::thrift::transport::TSocket> socket(new 
apache::thrift::transport::TSocket(ipAddress.c_str(), 
g_DaemonService_constants.DaemonService_port));
socket->setConnTimeout(connectionTimeout);
transport = 
boost::make_shared<apache::thrift::transport::TBufferedTransport>(socket);
client = 
boost::make_shared<DaemonServiceClient>(boost::make_shared<apache::thrift::protocol::TBinaryProtocol>(transport));
transport->open();

Kind regards,
Gianni

Mime
View raw message