[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[MiNT] [PATCH] nfeth.xif memory leak
Hello.
There is a huge memory leak in ARAnyM's nfeth.xif. Every packet sent
over the network is not freed. As a result, the free FastRAM quickly
shrinks when there is intensive network traffic. This is particularly
visible when using the iperf tool. It is even worse, as it is kernel
memory, and it is not automatically freed when the process exits.
The attached patch fixes this problem.
Alan, please commit!
nfeth.patch
Fixed memory leak in neth_output(). Contributed by Vincent Riviere.
--
Vincent Rivière
--- freemint.orig/sys/sockets/xif/nfeth/nfeth.c 2011-07-30 21:21:00.000000000 +0200
+++ freemint/sys/sockets/xif/nfeth/nfeth.c 2013-12-25 23:48:09.171875000 +0100
@@ -313,6 +313,8 @@
send_block (ethX, nbuf->dstart, len);
}
+ buf_deref (nbuf, BUF_NORMAL);
+
return 0;
}