Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
youngwolf
st_asio_wrapper
提交
924e7910
S
st_asio_wrapper
项目概览
youngwolf
/
st_asio_wrapper
通知
10
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
st_asio_wrapper
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
924e7910
编写于
2月 01, 2017
作者:
Y
youngwolf
提交者:
youngowlf
4月 27, 2018
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
A trivial change.
上级
56b7dc3d
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
26 addition
and
26 deletion
+26
-26
compatible_edition/test_client/test_client.cpp
compatible_edition/test_client/test_client.cpp
+13
-13
test_client/test_client.cpp
test_client/test_client.cpp
+13
-13
未找到文件。
compatible_edition/test_client/test_client.cpp
浏览文件 @
924e7910
...
...
@@ -378,7 +378,10 @@ void start_test(int repeat_times, char model, test_client& client, size_t send_t
if
(
0
==
model
)
send_msg_one_by_one
(
client
,
msg_num
,
msg_len
,
msg_fill
);
else
{
puts
(
"if ST_ASIO_WANT_MSG_SEND_NOTIFY defined, only support model 0!"
);
break
;
}
#else
if
(
0
==
model
)
send_msg_concurrently
(
client
,
send_thread_num
,
msg_num
,
msg_len
,
msg_fill
);
...
...
@@ -449,19 +452,7 @@ int main(int argc, const char* argv[])
std
::
string
str
;
std
::
getline
(
std
::
cin
,
str
);
if
(
str
.
empty
())
continue
;
else
if
(
is_testing
)
{
puts
(
"testing has not finished yet!"
);
continue
;
}
else
if
(
QUIT_COMMAND
==
str
)
sp
.
stop_service
();
else
if
(
RESTART_COMMAND
==
str
)
{
sp
.
stop_service
();
sp
.
start_service
(
thread_num
);
}
;
else
if
(
LIST_STATUS
==
str
)
{
printf
(
"link #: "
ST_ASIO_SF
", valid links: "
ST_ASIO_SF
", invalid links: "
ST_ASIO_SF
"
\n
"
,
client
.
size
(),
client
.
valid_size
(),
client
.
invalid_object_size
());
...
...
@@ -475,6 +466,15 @@ int main(int argc, const char* argv[])
client
.
do_something_to_all
(
boost
::
bind
(
&
test_socket
::
suspend_dispatch_msg
,
_1
,
false
));
else
if
(
LIST_ALL_CLIENT
==
str
)
client
.
list_all_object
();
else
if
(
is_testing
)
puts
(
"testing has not finished yet!"
);
else
if
(
QUIT_COMMAND
==
str
)
sp
.
stop_service
();
else
if
(
RESTART_COMMAND
==
str
)
{
sp
.
stop_service
();
sp
.
start_service
(
thread_num
);
}
else
{
if
(
'+'
==
str
[
0
]
||
'-'
==
str
[
0
])
...
...
test_client/test_client.cpp
浏览文件 @
924e7910
...
...
@@ -367,7 +367,10 @@ void start_test(int repeat_times, char model, test_client& client, size_t send_t
if
(
0
==
model
)
send_msg_one_by_one
(
client
,
msg_num
,
msg_len
,
msg_fill
);
else
{
puts
(
"if ST_ASIO_WANT_MSG_SEND_NOTIFY defined, only support model 0!"
);
break
;
}
#else
if
(
0
==
model
)
send_msg_concurrently
(
client
,
send_thread_num
,
msg_num
,
msg_len
,
msg_fill
);
...
...
@@ -438,19 +441,7 @@ int main(int argc, const char* argv[])
std
::
string
str
;
std
::
getline
(
std
::
cin
,
str
);
if
(
str
.
empty
())
continue
;
else
if
(
is_testing
)
{
puts
(
"testing has not finished yet!"
);
continue
;
}
else
if
(
QUIT_COMMAND
==
str
)
sp
.
stop_service
();
else
if
(
RESTART_COMMAND
==
str
)
{
sp
.
stop_service
();
sp
.
start_service
(
thread_num
);
}
;
else
if
(
LIST_STATUS
==
str
)
{
printf
(
"link #: "
ST_ASIO_SF
", valid links: "
ST_ASIO_SF
", invalid links: "
ST_ASIO_SF
"
\n
"
,
client
.
size
(),
client
.
valid_size
(),
client
.
invalid_object_size
());
...
...
@@ -464,6 +455,15 @@ int main(int argc, const char* argv[])
client
.
do_something_to_all
([](
test_client
::
object_ctype
&
item
)
{
item
->
suspend_dispatch_msg
(
false
);});
else
if
(
LIST_ALL_CLIENT
==
str
)
client
.
list_all_object
();
else
if
(
is_testing
)
puts
(
"testing has not finished yet!"
);
else
if
(
QUIT_COMMAND
==
str
)
sp
.
stop_service
();
else
if
(
RESTART_COMMAND
==
str
)
{
sp
.
stop_service
();
sp
.
start_service
(
thread_num
);
}
else
{
if
(
'+'
==
str
[
0
]
||
'-'
==
str
[
0
])
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录