1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-03-17 17:25:32 +00:00

Export uTP send_to callback.

This commit is contained in:
Juliusz Chroboczek 2011-02-18 00:36:16 +00:00
parent 11114a74c0
commit 456dbdd935
2 changed files with 7 additions and 4 deletions
libtransmission

View file

@ -75,9 +75,9 @@ incoming(void *closure, struct UTPSocket *s)
tr_peerMgrAddIncoming(ss->peerMgr, &addr, port, -1, s);
}
static void
send_to(void *closure, const unsigned char *buf, size_t buflen,
const struct sockaddr *to, socklen_t tolen)
void
tr_utpSendTo(void *closure, const unsigned char *buf, size_t buflen,
const struct sockaddr *to, socklen_t tolen)
{
tr_session *ss = (tr_session*)closure;
@ -115,7 +115,7 @@ tr_utpPacket(const unsigned char *buf, size_t buflen,
reset_timer();
}
return UTP_IsIncomingUTP(incoming, send_to, ss,
return UTP_IsIncomingUTP(incoming, tr_utpSendTo, ss,
buf, buflen, from, fromlen);
}

View file

@ -26,3 +26,6 @@ int tr_utpPacket(const unsigned char *buf, size_t buflen,
tr_session *ss);
void tr_utpClose( tr_session * );
void tr_utpSendTo(void *closure, const unsigned char *buf, size_t buflen,
const struct sockaddr *to, socklen_t tolen);