diff options
author | Luiz Augusto von Dentz <luiz.dentz@openbossa.org> | 2007-10-31 14:52:08 +0000 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.dentz@openbossa.org> | 2007-10-31 14:52:08 +0000 |
commit | 980c9cff04d70d6301c9538647872156b1b425eb (patch) | |
tree | b92bfc94e10a92813ca5cbbba54216bee357b46a /network/bridge.c | |
parent | 1884104ecb9b6b6a9ef6cc02d04e4861c9f1f6f6 (diff) |
Make the connection to fail if unable to add a interface to bridges.
Diffstat (limited to 'network/bridge.c')
-rw-r--r-- | network/bridge.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/network/bridge.c b/network/bridge.c index ad4fc72e..7dbbd616 100644 --- a/network/bridge.c +++ b/network/bridge.c @@ -42,8 +42,8 @@ #include "common.h" static int bridge_socket = -1; -static const char *gn_bridge; -static const char *nap_bridge; +static const char *gn_bridge = NULL; +static const char *nap_bridge = NULL; int bridge_init(const char *gn_iface, const char *nap_iface) { @@ -118,6 +118,10 @@ int bridge_add_interface(int id, const char *dev) if (err < 0) return err; + /* Only run scripts in GN bridges */ + if (id != BNEP_SVC_GN) + return 0; + err = bnep_if_up(name, id); if (err < 0) return err; |