Skip to content

Commit 2ca6866

Browse files
committed
add API function to receive lossless packets for given ID
1 parent 5fce3ff commit 2ca6866

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

jni-c-toxcore/jni-c-toxcore.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3364,6 +3364,18 @@ Java_com_zoffcc_applications_trifa_MainActivity_tox_1get_1all_1udp_1connections(
33643364
return result;
33653365
}
33663366

3367+
3368+
JNIEXPORT jint JNICALL
3369+
Java_com_zoffcc_applications_trifa_MainActivity_tox_1callback_1friend_1lossless_1packet_1per_1pktid(JNIEnv *env, jobject thiz, int pktid)
3370+
{
3371+
TRACE_LOGGER();
3372+
if(tox_global == NULL)
3373+
{
3374+
return -1;
3375+
}
3376+
tox_callback_friend_lossless_packet_per_pktid(tox_global, friend_lossless_packet_cb, pktid);
3377+
}
3378+
33673379
JNIEXPORT jstring JNICALL
33683380
Java_com_zoffcc_applications_trifa_MainActivity_get_1my_1toxid(JNIEnv *env, jobject thiz)
33693381
{

0 commit comments

Comments
 (0)