gateway: find_interfaceName only works in multi-gateway mode
authorFerry Huberts <ferry.huberts@pelagic.nl>
Tue, 29 Jan 2013 11:10:07 +0000 (12:10 +0100)
committerFerry Huberts <ferry.huberts@pelagic.nl>
Tue, 29 Jan 2013 14:40:42 +0000 (15:40 +0100)
Signed-off-by: Ferry Huberts <ferry.huberts@pelagic.nl>
src/gateway.c

index e86a605..6e74881 100644 (file)
@@ -177,6 +177,10 @@ static struct interfaceName * find_interfaceName(struct gateway_entry *gw) {
   struct interfaceName * sgwTunnelInterfaceNames;
   uint8_t i = 0;
 
+  if (!multi_gateway_mode()) {
+    return NULL;
+  }
+
   assert(sgwTunnel4InterfaceNames);
   assert(sgwTunnel6InterfaceNames);