dv_
31st July 2009, 20:27
Hello,
I am trying to get all local addresses on the host. I issue this call:
QList < QHostAddress > local_addresses = QHostInfo::fromName(QHostInfo::localHostName()).ad dresses();
But the resulting list has only one entry, "127.0.1.1", even though I have a running ethernet connection with its own IP. At the very least the list should have two entries, "127.0.1.1" and the NIC's IP.
Does anybody have an idea what's wrong?
I am trying to get all local addresses on the host. I issue this call:
QList < QHostAddress > local_addresses = QHostInfo::fromName(QHostInfo::localHostName()).ad dresses();
But the resulting list has only one entry, "127.0.1.1", even though I have a running ethernet connection with its own IP. At the very least the list should have two entries, "127.0.1.1" and the NIC's IP.
Does anybody have an idea what's wrong?