linklist memfree bugfix - volker milde

git-svn-id: svn://svn.code.sf.net/p/rdesktop/code/trunk/rdesktop@613 423420c4-83ab-492f-b58f-81f9feb106b5
This commit is contained in:
Peter Kallden 2004-02-23 12:07:30 +00:00
parent ce2181a3d3
commit ca4443a76e

View File

@ -824,12 +824,14 @@ rdpdr_check_fds(fd_set * rfds, fd_set * wfds, BOOL timed_out)
{ {
prev->next = iorq->next; prev->next = iorq->next;
xfree(iorq); xfree(iorq);
iorq = prev->next;
} }
else else
{ {
// Even if NULL // Even if NULL
g_iorequest = iorq->next; g_iorequest = iorq->next;
xfree(iorq); xfree(iorq);
iorq = NULL;
} }
} }
} }
@ -877,12 +879,14 @@ rdpdr_check_fds(fd_set * rfds, fd_set * wfds, BOOL timed_out)
{ {
prev->next = iorq->next; prev->next = iorq->next;
xfree(iorq); xfree(iorq);
iorq = prev->next;
} }
else else
{ {
// Even if NULL // Even if NULL
g_iorequest = iorq->next; g_iorequest = iorq->next;
xfree(iorq); xfree(iorq);
iorq = NULL;
} }
} }
} }
@ -891,7 +895,8 @@ rdpdr_check_fds(fd_set * rfds, fd_set * wfds, BOOL timed_out)
} }
prev = iorq; prev = iorq;
iorq = iorq->next; if (iorq)
iorq = iorq->next;
} }
} }