git.ucc.asn.au
/
tpg
/
acess2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
IPStack - Heaps of network fixes
[tpg/acess2.git]
/
Modules
/
IPStack
/
tcp.c
diff --git
a/Modules/IPStack/tcp.c
b/Modules/IPStack/tcp.c
index
3741503
..
18150a3
100644
(file)
--- a/
Modules/IPStack/tcp.c
+++ b/
Modules/IPStack/tcp.c
@@
-84,7
+84,7
@@
void TCP_SendPacket( tTCPConnection *Conn, size_t Length, tTCPHeader *Data )
buf[2] = (htons(Length)<<16) | (6<<8) | 0;
Data->Checksum = 0;
memcpy( &buf[3], Data, Length );
buf[2] = (htons(Length)<<16) | (6<<8) | 0;
Data->Checksum = 0;
memcpy( &buf[3], Data, Length );
- Data->Checksum =
IPv4_Checksum( buf, buflen
);
+ Data->Checksum =
htons( IPv4_Checksum( buf, buflen )
);
free(buf);
IPv4_SendPacket(Conn->Interface, Conn->RemoteIP.v4, IP4PROT_TCP, 0, Length, Data);
break;
free(buf);
IPv4_SendPacket(Conn->Interface, Conn->RemoteIP.v4, IP4PROT_TCP, 0, Length, Data);
break;
@@
-231,7
+231,7
@@
void TCP_GetPacket(tInterface *Interface, void *Address, int Length, void *Buffe
srv->ConnectionsTail = conn;
if(!srv->NewConnections)
srv->NewConnections = conn;
srv->ConnectionsTail = conn;
if(!srv->NewConnections)
srv->NewConnections = conn;
- SHORT
LOCK
(&srv->lConnections);
+ SHORT
REL
(&srv->lConnections);
// Send the SYN ACK
hdr->Flags |= TCP_FLAG_ACK;
// Send the SYN ACK
hdr->Flags |= TCP_FLAG_ACK;
UCC
git Repository :: git.ucc.asn.au