[moblab] Fix issue with network interface detection.

find_network_interfaces_by_ip_addr can be called twice if the WAN is
slow to get a IP address.

The first call has the side effect of setting the interface for the LAN to
be the first interface.

On each call to find_network_interfaces_by_ip_addr ensure that the WAN
and LAN interfaces are initialized to empty.

BUG=None
TEST=local moblab testing

Change-Id: Idfd8d498f3bac050948917ad339aaa8d74d940f3
Reviewed-on: https://chromium-review.googlesource.com/1544966
Commit-Ready: Keith Haddow <haddowk@chromium.org>
Tested-by: Keith Haddow <haddowk@chromium.org>
Reviewed-by: Matt Mallett <mattmallett@chromium.org>
diff --git a/src/upstart-scripts/moblab-network-bridge-init.conf b/src/upstart-scripts/moblab-network-bridge-init.conf
index 63440b6..2e491b9 100644
--- a/src/upstart-scripts/moblab-network-bridge-init.conf
+++ b/src/upstart-scripts/moblab-network-bridge-init.conf
@@ -70,6 +70,8 @@
   # The other interface has the DUT's connected, no DHCP server has been
   # started yet so no IP address on that interface.
   find_network_interfaces_by_ip_addr() {
+    INT_IFACE=""
+    EXT_IFACE=""
     logger -t "${UPSTART_JOB}" "Finding interfaces by ip address"
     local node
     local server_net_prefix=$( echo "${SERVER_ADDRESS}" |