gpt4 book ai didi

c - libwebsockets:Client类型属于哪个库?

转载 作者:行者123 更新时间:2023-11-30 16:38:38 24 4
gpt4 key购买 nike

我目前正在构建一个 WebSocket 服务器,我遇到了以下代码来处理碎片消息(来自 libwebsockets ):

case LWS_CALLBACK_RECEIVE:
{
Client * const client = (Client *)user;
const size_t remaining = libwebsockets_remaining_packet_payload(wsi);
if (0 == remaining &&
libwebsocket_is_final_fragment(wsi))
{
if (client->HasFragments())
{
client->AppendMessageFragment(in, len, 0);
in = (void *)client->GetMessage();
len = client->GetMessageLength();
}

client->ProcessMessage((char *)in, len, wsi);

client->ResetMessage();
}
else
{
client->AppendMessageFragment(in, len, remaining);
}
}
break;

我的问题是,Client 类型是什么?我应该将哪个库/ header 添加到我的代码中?

最佳答案

您正在查看该项目过时分支中的过时自述文件。前往the active projectvisit the official page .

关于c - libwebsockets:Client类型属于哪个库?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47425202/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com