+ struct sockaddr *addr;
+ fio_socklen_t socklen;
+ int fd, domain;
+
+ if (client->ipv6) {
+ client->addr6.sin6_family = AF_INET6;
+ client->addr6.sin6_port = htons(client->port);
+ domain = AF_INET6;
+ addr = (struct sockaddr *) &client->addr6;
+ socklen = sizeof(client->addr6);
+ } else {
+ client->addr.sin_family = AF_INET;
+ client->addr.sin_port = htons(client->port);
+ domain = AF_INET;
+ addr = (struct sockaddr *) &client->addr;
+ socklen = sizeof(client->addr);
+ }