diff --git a/src/network/net_modem.c b/src/network/net_modem.c index bbbe2e37a1..b1b6a2eca5 100644 --- a/src/network/net_modem.c +++ b/src/network/net_modem.c @@ -1,4 +1,3 @@ - /* * 86Box A hypervisor and IBM PC system emulator that specializes in * running old operating systems and software designed for IBM @@ -323,9 +322,9 @@ process_tx_packet(modem_t *modem, uint8_t *p, uint32_t len) buf[13] = 0x00; memcpy(buf + 14, processed_tx_packet, received); network_tx(modem->card, buf, received + 14); - free(processed_tx_packet); free(buf); } + free(processed_tx_packet); return; } @@ -530,6 +529,7 @@ modem_enter_connected_state(modem_t* modem) modem->connected = true; modem->tcpIpMode = true; modem->cooldown = true; + modem->tx_count = 0; plat_netsocket_close(modem->serversocket); modem->serversocket = -1; memset(&modem->telClient, 0, sizeof(modem->telClient));