mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-20 09:20:04 +01:00
dhcp: dhcpcd uses a fixed path for PID files
It always uses RUNDIR and the change to NMRUNDIR was in error. This could cause NetworkManager not to be able to kill old dhcpcd processes.
This commit is contained in:
parent
b11aec3f15
commit
e2ecf5b808
2 changed files with 5 additions and 1 deletions
|
|
@ -368,6 +368,7 @@ AM_CPPFLAGS += \
|
|||
-DLOCALSTATEDIR=\"$(localstatedir)\" \
|
||||
-DSBINDIR=\"$(sbindir)\" \
|
||||
-DSYSCONFDIR=\"$(sysconfdir)\" \
|
||||
-DRUNDIR=\"$(rundir)\" \
|
||||
\
|
||||
-DNMCONFDIR=\"$(nmconfdir)\" \
|
||||
-DNMLOCALEDIR=\"$(datadir)/locale\" \
|
||||
|
|
|
|||
|
|
@ -103,7 +103,10 @@ ip4_start (NMDHCPClient *client,
|
|||
|
||||
iface = nm_dhcp_client_get_iface (client);
|
||||
|
||||
priv->pid_file = g_strdup_printf (NMSTATEDIR "/dhcpcd-%s.pid", iface);
|
||||
/* dhcpcd does not allow custom pidfiles; the pidfile is always
|
||||
* RUNDIR "dhcpcd-<ifname>.pid".
|
||||
*/
|
||||
priv->pid_file = g_strdup_printf (RUNDIR "/dhcpcd-%s.pid", iface);
|
||||
|
||||
if (!g_file_test (priv->path, G_FILE_TEST_EXISTS)) {
|
||||
nm_log_warn (LOGD_DHCP4, "%s does not exist.", priv->path);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue