diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2005-06-02 20:36:33 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2005-06-02 20:36:33 +0000 |
commit | 335978db776a55b5a2d178da15b9ba06c6f5fb65 (patch) | |
tree | cdbc5d02055feae2867a2150fc356a87cca26808 /etc | |
parent | dc22c75cedda7f4cc707aef1d51e792c358f5455 (diff) | |
download | pfsense-335978db776a55b5a2d178da15b9ba06c6f5fb65.zip pfsense-335978db776a55b5a2d178da15b9ba06c6f5fb65.tar.gz |
Add find_number_of_created_bridges() routine which returns the number of currently created bridges
*/
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/pfsense-utils.inc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/etc/inc/pfsense-utils.inc b/etc/inc/pfsense-utils.inc index 6641905..657ec25 100644 --- a/etc/inc/pfsense-utils.inc +++ b/etc/inc/pfsense-utils.inc @@ -418,6 +418,13 @@ function find_carp_interface($ip) { } /* + * find_number_of_created_bridges(): returns the number of currently created bridges + */ +function find_number_of_created_bridges() { + return `/sbin/ifconfig | grep \"bridge[0-999]\:" | wc -l`; +} + +/* * add_rule_to_anchor($anchor, $rule): adds the specified rule to an anchor */ function add_rule_to_anchor($anchor, $rule, $label) { |