mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-24 21:50:17 +01:00
ppp-manager: initialize MTU to zero when not specified
When the MTU was not specified in PPP setting, it got the value of a
previous option.
Fixes: 8f36727ac8
This commit is contained in:
parent
ac7a6d0206
commit
986cf3a887
1 changed files with 5 additions and 4 deletions
|
|
@ -433,10 +433,11 @@ set_ip_config_common (NMPPPManager *self,
|
|||
applied_connection = nm_act_request_get_applied_connection (priv->act_req);
|
||||
g_object_set_data (G_OBJECT (applied_connection), PPP_MANAGER_SECRET_TRIES, NULL);
|
||||
|
||||
/* Get any custom MTU */
|
||||
s_ppp = nm_connection_get_setting_ppp (applied_connection);
|
||||
if (s_ppp && out_mtu)
|
||||
*out_mtu = nm_setting_ppp_get_mtu (s_ppp);
|
||||
if (out_mtu) {
|
||||
/* Get any custom MTU */
|
||||
s_ppp = nm_connection_get_setting_ppp (applied_connection);
|
||||
*out_mtu = s_ppp ? nm_setting_ppp_get_mtu (s_ppp) : 0;
|
||||
}
|
||||
|
||||
monitor_stats (self);
|
||||
return TRUE;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue