From d29de4797de9a3cc3920c55d01b0a2b0c1cf20c61965d84008fb4c522a89d2e4 Mon Sep 17 00:00:00 2001 From: Marius Tomaschewski Date: Fri, 10 Jan 2014 12:13:49 +0000 Subject: [PATCH 1/3] - Test if /etc/sysconfig/network/scripts/functions exists before sourcing it (fate#316768,bnc#856591). OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=117 --- dhclient-script | 4 +++- dhcp.changes | 6 ++++++ dhcp.spec | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/dhclient-script b/dhclient-script index 2ecc8f2..d7fd8a5 100644 --- a/dhclient-script +++ b/dhclient-script @@ -21,7 +21,9 @@ test "x$reason" = x -o "x$interface" = x && exit 1 # source sysconfig functions # SYSCONFIG_CFG_DIR="/etc/sysconfig/network" -. "$SYSCONFIG_CFG_DIR/scripts/functions" +if test -f "$SYSCONFIG_CFG_DIR/scripts/functions" ; then + . "$SYSCONFIG_CFG_DIR/scripts/functions" +fi SYSCONFIG_RUN_DIR=${SYSCONFIG_RUN_DIR:-/dev/.sysconfig/network} # diff --git a/dhcp.changes b/dhcp.changes index 217d3f8..bbbbc22 100644 --- a/dhcp.changes +++ b/dhcp.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Jan 10 12:05:22 UTC 2014 - mt@suse.com + +- Test if /etc/sysconfig/network/scripts/functions exists before + sourcing it (fate#316768,bnc#856591). + ------------------------------------------------------------------- Mon Nov 18 09:40:55 UTC 2013 - mt@suse.com diff --git a/dhcp.spec b/dhcp.spec index 48d2085..9891c2f 100644 --- a/dhcp.spec +++ b/dhcp.spec @@ -1,7 +1,7 @@ # # spec file for package dhcp # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed From f86cd46c029515c545c176ea783c38a5b12a122138b02d250ab193c29c4ccfa8 Mon Sep 17 00:00:00 2001 From: Marius Tomaschewski Date: Fri, 10 Jan 2014 12:17:07 +0000 Subject: [PATCH 2/3] One more place OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=118 --- if-up.d.dhcpd-restart-hook | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/if-up.d.dhcpd-restart-hook b/if-up.d.dhcpd-restart-hook index a83ab27..a203f9b 100644 --- a/if-up.d.dhcpd-restart-hook +++ b/if-up.d.dhcpd-restart-hook @@ -51,7 +51,9 @@ fi . /etc/sysconfig/network/config -. /etc/sysconfig/network/scripts/functions +if test -f /etc/sysconfig/network/scripts/functions ; then + /etc/sysconfig/network/scripts/functions +fi . /etc/sysconfig/dhcpd 2>/dev/null . /etc/sysconfig/network/ifcfg-"$CONFIG" 2>/dev/null || true From f1f840f0e71f22f72db47fbbd5e3f25c7ff87d9546f755929534ccff1ced356e Mon Sep 17 00:00:00 2001 From: Marius Tomaschewski Date: Fri, 10 Jan 2014 12:17:54 +0000 Subject: [PATCH 3/3] fixed typo OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=119 --- if-up.d.dhcpd-restart-hook | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/if-up.d.dhcpd-restart-hook b/if-up.d.dhcpd-restart-hook index a203f9b..c0ae2a0 100644 --- a/if-up.d.dhcpd-restart-hook +++ b/if-up.d.dhcpd-restart-hook @@ -52,7 +52,7 @@ fi . /etc/sysconfig/network/config if test -f /etc/sysconfig/network/scripts/functions ; then - /etc/sysconfig/network/scripts/functions + . /etc/sysconfig/network/scripts/functions fi . /etc/sysconfig/dhcpd 2>/dev/null