diff --git a/ports/bsd/bip-init.c b/ports/bsd/bip-init.c index f6df2989..d0b17bfe 100644 --- a/ports/bsd/bip-init.c +++ b/ports/bsd/bip-init.c @@ -763,6 +763,9 @@ void bip_cleanup(void) close(BIP_Broadcast_Socket); } BIP_Broadcast_Socket = -1; + /* these were set non-zero during interface configuration */ + BIP_Address.s_addr = 0; + BIP_Broadcast_Addr.s_addr = 0; return; } diff --git a/ports/linux/bip-init.c b/ports/linux/bip-init.c index 65ae1a4a..182112f5 100644 --- a/ports/linux/bip-init.c +++ b/ports/linux/bip-init.c @@ -955,6 +955,9 @@ void bip_cleanup(void) close(BIP_Broadcast_Socket); } BIP_Broadcast_Socket = -1; + /* these were set non-zero during interface configuration */ + BIP_Address.s_addr = 0; + BIP_Broadcast_Addr.s_addr = 0; return; } diff --git a/ports/win32/bip-init.c b/ports/win32/bip-init.c index 8c7b5c22..9b4c8d92 100644 --- a/ports/win32/bip-init.c +++ b/ports/win32/bip-init.c @@ -920,6 +920,9 @@ void bip_cleanup(void) BIP_Initialized = false; WSACleanup(); } + /* these were set non-zero during interface configuration */ + BIP_Address.s_addr = 0; + BIP_Broadcast_Addr.s_addr = 0; return; }