Skip to content

Commit 2746f4f

Browse files
committed
rebasing with upstream
2 parents 3a2af5d + 31a4137 commit 2746f4f

File tree

16 files changed

+3893
-5
lines changed

16 files changed

+3893
-5
lines changed

features/FEATURE_LWIP/lwip-interface/lwip_stack.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -625,11 +625,13 @@ nsapi_error_t mbed_lwip_emac_init(emac_interface_t *emac)
625625
// Backwards compatibility with people using DEVICE_EMAC
626626
nsapi_error_t mbed_lwip_init(emac_interface_t *emac)
627627
{
628-
nsapi_error_t ret;
628+
nsapi_error_t ret = NSAPI_ERROR_OK;
629629
mbed_lwip_core_init();
630-
ret = mbed_lwip_emac_init(emac);
631-
if (ret == NSAPI_ERROR_OK) {
632-
netif_inited = true;
630+
if(netif_inited == false){
631+
ret = mbed_lwip_emac_init(emac);
632+
if (ret == NSAPI_ERROR_OK) {
633+
netif_inited = true;
634+
}
633635
}
634636
return ret;
635637
}

0 commit comments

Comments
 (0)