3e961a6f06
This reverts commit 3b709249ea
.
Unretirement request: https://pagure.io/releng/issue/8733
28 lines
728 B
Diff
28 lines
728 B
Diff
Index: src/lib/Libifl/tcp_dis.c
|
|
===================================================================
|
|
--- src/lib/Libifl/tcp_dis.c (revision 5269)
|
|
+++ src/lib/Libifl/tcp_dis.c (revision 5270)
|
|
@@ -797,12 +797,19 @@
|
|
{
|
|
struct tcp_chan *tcp;
|
|
|
|
+ /* On startup tcparray may not yet be initialized. check it */
|
|
+ if (tcparray == NULL)
|
|
+ return;
|
|
+
|
|
+ if (fd > tcparraymax)
|
|
+ return;
|
|
+
|
|
tcp = tcparray[fd];
|
|
- if(tcp != NULL)
|
|
+ if (tcp != NULL)
|
|
{
|
|
- if(tcp->readbuf.tdis_thebuf != NULL)
|
|
+ if (tcp->readbuf.tdis_thebuf != NULL)
|
|
free(tcp->readbuf.tdis_thebuf);
|
|
- if(tcp->writebuf.tdis_thebuf != NULL)
|
|
+ if (tcp->writebuf.tdis_thebuf != NULL)
|
|
free(tcp->writebuf.tdis_thebuf);
|
|
|
|
free(tcp);
|