p->m_socket = socket(AF_INET, SOCK_STREAM, 0);
if (p->m_socket == YAZ_INVALID_SOCKET)
{
p->m_socket = socket(AF_INET, SOCK_STREAM, 0);
if (p->m_socket == YAZ_INVALID_SOCKET)
{
add.sin_family = AF_INET;
add.sin_port = htons(port_to_use);
add.sin_addr.s_addr = INADDR_ANY;
add.sin_family = AF_INET;
add.sin_port = htons(port_to_use);
add.sin_addr.s_addr = INADDR_ANY;