Andrew Boyson / net

Dependents:   oldheating gps motorhome heating

Revision:
83:08c983006a6e
Parent:
82:20781198d26d
Child:
87:40d46a979cdb
--- a/tcp/tcpsend.c	Thu Nov 15 18:42:42 2018 +0000
+++ b/tcp/tcpsend.c	Sat Nov 17 15:49:03 2018 +0000
@@ -184,10 +184,10 @@
 
 int TcpPollForPacketToSend(int* pSize, void* pPacket, int ipType, int* pRemArIndex, int* pLocIpScope)
 {
-    //This loops around the TCBs, moving on if empty but staying if not the right type
+    //Loops around the TCBs, moving on if empty but staying if not the right type
     static struct tcb* pTcb = NULL; //Passing a pointer containing NULL to TcbGetNext causes it to return the first TCB
     static bool stay = false;
-    if (!stay) TcbGetNext(&pTcb);
+    if (!stay) pTcb = TcbGetNext(pTcb);
     stay = false;
     if (!pTcb->state) return DO_NOTHING;
     if (pTcb->ipType != ipType)