第一次使用后发现的问题
bigbao9494 opened this issue · 3 comments
环境win10+vs2019:
mkdir -p vs
xmake project -k vsxmake -a "x64,x86" -m "debug" vs
问题1:
echo.cc中的conn_cb函数:
int r = conn.recvn(&buf[0], FLG_l);
会造成fast.h中的断言:
const char& front() const {
assert(_size > 0);
return _p[0];
}
好像是fastream中的capacity和size概念问题。
问题2:
修改上面问题后,程序也并没有按照client_server间数据Ping_pong
conn_cb函数中接收到一次数据后send就一直阻塞。
问题3:执行.\http_cli.exe -s 0.0.0.0:80
F0224 14:06:06.627 15124 http.cc:340] check failed: false! To use http::Client, please build libco with libcurl as follow:
xmake f --with_libcurl=true
xmake -v
minkernel\crts\ucrt\src\appcrt\misc\dbgrpt.cpp (278): _CrtDbgReportW
minkernel\crts\ucrt\src\appcrt\internal\report_runtime_error.cpp (25): issue_debug_notification
minkernel\crts\ucrt\src\appcrt\internal\report_runtime_error.cpp (154): __acrt_report_runtime_error
minkernel\crts\ucrt\src\appcrt\startup\abort.cpp (61): abort
D:\I\cpp_go\other_lib\coost\coost-master\src\log\log.cc (518): ___::log::xx::Logger::push_fatal_log
D:\I\cpp_go\other_lib\coost\coost-master\src\log\log.cc (961): ___::log::xx::FatalLogSaver::~FatalLogSaver
D:\I\cpp_go\other_lib\coost\coost-master\src\so\http.cc (344): http::Client::Client
D:\I\cpp_go\other_lib\coost\coost-master\test\so\http_cli.cc (12): fa
D:\I\cpp_go\other_lib\coost\coost-master\include\co\closure.h (44): co::xx::Function0p<void __cdecl(void)>::run
D:\I\cpp_go\other_lib\coost\coost-master\src\co\scheduler.cc (42): co::SchedulerImpl::main_func
D:\I\cpp_go\other_lib\coost\coost-master\src\co\context\context_x64.asm (155): tb_context_make
000000579ACFF9E0 ((module-name not available)): (filename not available): (function-name not available)
CDCDCDCDCDCDCDCD ((module-name not available)): (filename not available): (function-name not available)
000000579ACFF9E0 ((module-name not available)): (filename not available): (function-name not available)
0000018A9A199070 ((module-name not available)): (filename not available): (function-name not available)
00000000FDFDFDFD ((module-name not available)): (filename not available): (function-name not available)
问题4:coost的协程和网络库相关是否有工程应用?
1、最近测试代码忘改过来了
2、应该是用法问题
3、已经有提示了,需要libcurl
F0224 14:06:06.627 15124 http.cc:340] check failed: false! To use http::Client, please build libco with libcurl as follow:
xmake f --with_libcurl=true
xmake -v
@idealvin 麻烦还有一个问题
问题2用法问题,是示例中原始代码,你是说那个示例写得有问题?
测试了问题2中示例echo,在LINUX下没有问题,在WINDOWS平台下的问题,可能和WIN下的IO相关吧。
问题4:coost的协程和网络库相关是否有工程应用?
还有就是问题3,正确姿势是怎样的?
用 3.0.1 版本,看看参考文档