mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-28 11:10:37 +02:00
dhcp: chain up parent stop() for NMDhcpSystem client
The parent's stop() implementation does nothing interesting for NMDhcpSystem. Still, call it, it's just unexpected to not chain up the parent implementation, if all other subclasses do it. In general, if the parent's implementation is not suitable to be called by the derived class, that should be handled differently then just not chaining up. Otherwise it's inconsistent and confusing.
This commit is contained in:
parent
056f2679b8
commit
badace72dd
3 changed files with 2 additions and 2 deletions
|
|
@ -564,7 +564,6 @@ stop (NMDhcpClient *client, gboolean release, const GByteArray *duid)
|
|||
NMDhcpDhclient *self = NM_DHCP_DHCLIENT (client);
|
||||
NMDhcpDhclientPrivate *priv = NM_DHCP_DHCLIENT_GET_PRIVATE (self);
|
||||
|
||||
/* Chain up to parent */
|
||||
NM_DHCP_CLIENT_CLASS (nm_dhcp_dhclient_parent_class)->stop (client, release, duid);
|
||||
|
||||
if (priv->conf_file)
|
||||
|
|
|
|||
|
|
@ -194,7 +194,6 @@ stop (NMDhcpClient *client, gboolean release, const GByteArray *duid)
|
|||
NMDhcpDhcpcd *self = NM_DHCP_DHCPCD (client);
|
||||
NMDhcpDhcpcdPrivate *priv = NM_DHCP_DHCPCD_GET_PRIVATE (self);
|
||||
|
||||
/* Chain up to parent */
|
||||
NM_DHCP_CLIENT_CLASS (nm_dhcp_dhcpcd_parent_class)->stop (client, release, duid);
|
||||
|
||||
if (priv->pid_file) {
|
||||
|
|
|
|||
|
|
@ -1020,6 +1020,8 @@ stop (NMDhcpClient *client, gboolean release, const GByteArray *duid)
|
|||
NMDhcpSystemdPrivate *priv = NM_DHCP_SYSTEMD_GET_PRIVATE (self);
|
||||
int r = 0;
|
||||
|
||||
NM_DHCP_CLIENT_CLASS (nm_dhcp_systemd_parent_class)->stop (client, release, duid);
|
||||
|
||||
_LOGT ("dhcp-client%d: stop %p",
|
||||
priv->client4 ? '4' : '6',
|
||||
priv->client4 ? (gpointer) priv->client4 : (gpointer) priv->client6);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue