From: Michael Tremer Date: Sun, 23 Sep 2012 14:18:20 +0000 (+0000) Subject: Remove the event system which is not needed. X-Git-Tag: 005~28 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=baf777ccda0aafeb96c57ee9dbc7eff001607947;p=network.git Remove the event system which is not needed. --- diff --git a/functions.events b/functions.events deleted file mode 100644 index 5b5ba800..00000000 --- a/functions.events +++ /dev/null @@ -1,64 +0,0 @@ -#!/bin/bash -############################################################################### -# # -# IPFire.org - A linux based firewall # -# Copyright (C) 2010 Michael Tremer & Christian Schmidt # -# # -# This program is free software: you can redistribute it and/or modify # -# it under the terms of the GNU General Public License as published by # -# the Free Software Foundation, either version 3 of the License, or # -# (at your option) any later version. # -# # -# This program is distributed in the hope that it will be useful, # -# but WITHOUT ANY WARRANTY; without even the implied warranty of # -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # -# GNU General Public License for more details. # -# # -# You should have received a copy of the GNU General Public License # -# along with this program. If not, see . # -# # -############################################################################### - -function event_emit() { - local event=${1} - shift - - log DEBUG "Emitting event '${event}' ($@)" - - # XXX Since we have no more upstart, we do nothing here for now. - # At a later point of time, we need to find another solution how to - # react on those events. - #initctl emit ${event} $@ - - case "${event}" in - firewall-reload) - # Try to reload the firewall service. - __event_firewall_reload - ;; - esac -} - -function __event_firewall_reload() { - local service="firewall" - - # Reload the firewall service when it has - # been started earlier. - if service_is_running ${service}; then - service_restart ${service} - fi -} - -function event_interface_up() { - local iface=${1} - - event_emit network-interface-up IFACE=${iface} - - # XXX Just for now - routing_default_update -} - -function event_interface_down() { - local iface=${1} - - event_emit network-interface-down IFACE=${iface} -} diff --git a/functions.ppp b/functions.ppp index 3e7c0a70..c041389a 100644 --- a/functions.ppp +++ b/functions.ppp @@ -84,9 +84,6 @@ function ppp_common_ip_pre_up() { routing_db_from_ppp ${zone} ipv4 - # Request firewall reload - event_emit firewall-reload - return ${EXIT_OK} } @@ -103,9 +100,6 @@ function ppp_common_ip_up() { routing_update ${zone} ipv4 routing_default_update - # Emit interface-up event - event_interface_up ${zone} - return ${EXIT_OK} } @@ -127,9 +121,6 @@ function ppp_common_ip_down() { # Save accounting information ppp_accounting ${zone} - # Emit interface-up event - event_interface_down ${zone} - return ${EXIT_OK} } @@ -149,9 +140,6 @@ function ppp_common_ipv6_up() { routing_update ${zone} ipv6 routing_default_update - # Emit interface-up event - event_interface_up ${zone} - return ${EXIT_OK} } @@ -173,9 +161,6 @@ function ppp_common_ipv6_down() { # Save accounting information ppp_accounting ${zone} - # Emit interface-up event - event_interface_down ${zone} - return ${EXIT_OK} } diff --git a/hooks/zones/wireless b/hooks/zones/wireless index a150cfd4..23279db0 100755 --- a/hooks/zones/wireless +++ b/hooks/zones/wireless @@ -86,8 +86,6 @@ function _up() { zone_configs_up ${zone} - event_interface_up ${zone} - exit ${EXIT_OK} } @@ -100,8 +98,6 @@ function _down() { exit ${EXIT_OK} fi - event_interface_down ${zone} - zone_configs_down ${zone} wpa_supplicant_stop ${zone}