dhcp-3.0.3-dhclient-dbus.patch 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. --- client/scripts/bsdos
  2. +++ client/scripts/bsdos
  3. @@ -47,6 +47,11 @@
  4. . /etc/dhcp/dhclient-exit-hooks
  5. fi
  6. # probably should do something with exit status of the local script
  7. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  8. + dbus-send --system --dest=com.redhat.dhcp \
  9. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  10. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  11. + fi
  12. exit $exit_status
  13. }
  14. --- client/scripts/freebsd
  15. +++ client/scripts/freebsd
  16. @@ -57,6 +57,11 @@
  17. . /etc/dhcp/dhclient-exit-hooks
  18. fi
  19. # probably should do something with exit status of the local script
  20. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  21. + dbus-send --system --dest=com.redhat.dhcp \
  22. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  23. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  24. + fi
  25. exit $exit_status
  26. }
  27. --- client/scripts/linux
  28. +++ client/scripts/linux
  29. @@ -69,6 +69,11 @@
  30. . /etc/dhcp/dhclient-exit-hooks
  31. fi
  32. # probably should do something with exit status of the local script
  33. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  34. + dbus-send --system --dest=com.redhat.dhcp \
  35. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  36. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  37. + fi
  38. exit $exit_status
  39. }
  40. --- client/scripts/netbsd
  41. +++ client/scripts/netbsd
  42. @@ -47,6 +47,11 @@
  43. . /etc/dhcp/dhclient-exit-hooks
  44. fi
  45. # probably should do something with exit status of the local script
  46. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  47. + dbus-send --system --dest=com.redhat.dhcp \
  48. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  49. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  50. + fi
  51. exit $exit_status
  52. }
  53. --- client/scripts/openbsd
  54. +++ client/scripts/openbsd
  55. @@ -47,6 +47,11 @@
  56. . /etc/dhcp/dhclient-exit-hooks
  57. fi
  58. # probably should do something with exit status of the local script
  59. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  60. + dbus-send --system --dest=com.redhat.dhcp \
  61. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  62. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  63. + fi
  64. exit $exit_status
  65. }
  66. --- client/scripts/solaris
  67. +++ client/scripts/solaris
  68. @@ -47,6 +47,11 @@
  69. . /etc/dhcp/dhclient-exit-hooks
  70. fi
  71. # probably should do something with exit status of the local script
  72. + if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
  73. + dbus-send --system --dest=com.redhat.dhcp \
  74. + --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
  75. + 'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
  76. + fi
  77. exit $exit_status
  78. }