diff --git a/src/network/kernel/qnetworkinterface.cpp b/src/network/kernel/qnetworkinterface.cpp index 70674e9adf..75a26848a6 100644 --- a/src/network/kernel/qnetworkinterface.cpp +++ b/src/network/kernel/qnetworkinterface.cpp @@ -706,7 +706,7 @@ int QNetworkInterface::index() const \sa QUdpSocket */ -int QNetworkInterface::maxTransmissionUnit() const +int QNetworkInterface::maximumTransmissionUnit() const { return d ? d->mtu : 0; } diff --git a/src/network/kernel/qnetworkinterface.h b/src/network/kernel/qnetworkinterface.h index f7ef192dc0..148fd5e10d 100644 --- a/src/network/kernel/qnetworkinterface.h +++ b/src/network/kernel/qnetworkinterface.h @@ -153,7 +153,7 @@ public: bool isValid() const; int index() const; - int maxTransmissionUnit() const; + int maximumTransmissionUnit() const; QString name() const; QString humanReadableName() const; InterfaceFlags flags() const; diff --git a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp index 0b4ed4870d..b73ed8eaec 100644 --- a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp +++ b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp @@ -143,7 +143,7 @@ void tst_QNetworkInterface::dump() qDebug() << " flags: " << qPrintable(flags); qDebug() << " type: " << i.type(); qDebug() << " hw address:" << qPrintable(i.hardwareAddress()); - qDebug() << " MTU: " << i.maxTransmissionUnit(); + qDebug() << " MTU: " << i.maximumTransmissionUnit(); int count = 0; foreach (const QNetworkAddressEntry &e, i.addressEntries()) { @@ -187,7 +187,7 @@ void tst_QNetworkInterface::consistencyCheck() if (iface.index()) interfaceIndexes << iface.index(); - QVERIFY(iface.maxTransmissionUnit() >= 0); + QVERIFY(iface.maximumTransmissionUnit() >= 0); const QList addresses = iface.addressEntries(); for (auto entry : addresses) { @@ -275,7 +275,7 @@ void tst_QNetworkInterface::localAddress() << "pmtu" << pmtu; // check that the Path MTU is less than or equal the interface's MTU - QVERIFY(pmtu <= outgoingIface->maxTransmissionUnit()); + QVERIFY(pmtu <= outgoingIface->maximumTransmissionUnit()); } void tst_QNetworkInterface::interfaceFromXXX_data()