Commit 9c2efb9a authored by JINMEI Tatuya's avatar JINMEI Tatuya
Browse files

minor style fix: treat "xxx" as std::string, not char *


git-svn-id: svn://bind10.isc.org/svn/bind10/branches/f2f200910@205 e5f2f494-b856-4b98-b285-d166d9295462
parent 1a4f7fa8
......@@ -13,13 +13,13 @@ using namespace std; // I don't understand why this is needed for cout
using namespace isc::dns;
char* dns_type = NULL; // not set, so A, AAAA, MX
char* server = "127.0.0.1";
std::string server = "127.0.0.1";
int verbose = 1; // later make this an option and default to 0
int first_time = 1;
struct timeval before_time, after_time;
int
host_lookup(char* name, char* type)
host_lookup(char* name, std::string type)
{
Message msg;
......@@ -44,7 +44,7 @@ host_lookup(char* name, char* type)
hints.ai_family = AF_UNSPEC;
hints.ai_socktype = SOCK_DGRAM;
hints.ai_flags = 0; // not using AI_NUMERICHOST in case to bootstrap
e = getaddrinfo(server, "53", &hints, &res);
e = getaddrinfo(server.c_str(), "53", &hints, &res);
if (verbose) {
cout << "Trying \"" << name << "\"\n";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment