Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
057b889a
Commit
057b889a
authored
Jan 14, 2015
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix typo: "sever => server"
parent
cc66ef18
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
7 deletions
+7
-7
examples/brokers/simple_broker.cpp
examples/brokers/simple_broker.cpp
+2
-2
examples/brokers/simple_http_broker.cpp
examples/brokers/simple_http_broker.cpp
+2
-2
libcaf_io/caf/io/basp_broker.hpp
libcaf_io/caf/io/basp_broker.hpp
+1
-1
libcaf_io/src/basp_broker.cpp
libcaf_io/src/basp_broker.cpp
+2
-2
No files found.
examples/brokers/simple_broker.cpp
View file @
057b889a
...
@@ -175,8 +175,8 @@ int main(int argc, char** argv) {
...
@@ -175,8 +175,8 @@ int main(int argc, char** argv) {
on
(
"-s"
,
as_u16
)
>>
[
&
](
uint16_t
port
)
{
on
(
"-s"
,
as_u16
)
>>
[
&
](
uint16_t
port
)
{
cout
<<
"run in server mode"
<<
endl
;
cout
<<
"run in server mode"
<<
endl
;
auto
pong_actor
=
spawn
(
pong
);
auto
pong_actor
=
spawn
(
pong
);
auto
sever_actor
=
spawn_io_server
(
server
,
port
,
pong_actor
);
auto
se
r
ver_actor
=
spawn_io_server
(
server
,
port
,
pong_actor
);
print_on_exit
(
sever_actor
,
"server"
);
print_on_exit
(
se
r
ver_actor
,
"server"
);
print_on_exit
(
pong_actor
,
"pong"
);
print_on_exit
(
pong_actor
,
"pong"
);
},
},
on
(
"-c"
,
val
<
string
>
,
as_u16
)
>>
[
&
](
const
string
&
host
,
uint16_t
port
)
{
on
(
"-c"
,
val
<
string
>
,
as_u16
)
>>
[
&
](
const
string
&
host
,
uint16_t
port
)
{
...
...
examples/brokers/simple_http_broker.cpp
View file @
057b889a
...
@@ -74,12 +74,12 @@ int main(int argc, const char **argv) {
...
@@ -74,12 +74,12 @@ int main(int argc, const char **argv) {
on
(
"-p"
,
as_u16
)
>>
[
&
](
uint16_t
port
)
{
on
(
"-p"
,
as_u16
)
>>
[
&
](
uint16_t
port
)
{
cout
<<
"*** run in server mode listen on: "
<<
port
<<
endl
;
cout
<<
"*** run in server mode listen on: "
<<
port
<<
endl
;
cout
<<
"*** to quit the program, simply press <enter>"
<<
endl
;
cout
<<
"*** to quit the program, simply press <enter>"
<<
endl
;
auto
sever_actor
=
spawn_io_server
(
server
,
port
);
auto
se
r
ver_actor
=
spawn_io_server
(
server
,
port
);
// wait for any input
// wait for any input
std
::
string
dummy
;
std
::
string
dummy
;
std
::
getline
(
std
::
cin
,
dummy
);
std
::
getline
(
std
::
cin
,
dummy
);
// kill server
// kill server
anon_send_exit
(
sever_actor
,
exit_reason
::
user_shutdown
);
anon_send_exit
(
se
r
ver_actor
,
exit_reason
::
user_shutdown
);
},
},
others
()
>>
[]
{
others
()
>>
[]
{
cerr
<<
"use with '-p PORT' as server on port"
<<
endl
;
cerr
<<
"use with '-p PORT' as server on port"
<<
endl
;
...
...
libcaf_io/caf/io/basp_broker.hpp
View file @
057b889a
...
@@ -129,7 +129,7 @@ class basp_broker : public broker, public actor_namespace::backend {
...
@@ -129,7 +129,7 @@ class basp_broker : public broker, public actor_namespace::backend {
void
init_handshake_as_client
(
connection_context
&
ctx
);
void
init_handshake_as_client
(
connection_context
&
ctx
);
void
init_handshake_as_sever
(
connection_context
&
ctx
,
void
init_handshake_as_se
r
ver
(
connection_context
&
ctx
,
actor_addr
published_actor
);
actor_addr
published_actor
);
void
serialize_msg
(
const
actor_addr
&
sender
,
message_id
mid
,
void
serialize_msg
(
const
actor_addr
&
sender
,
message_id
mid
,
...
...
libcaf_io/src/basp_broker.cpp
View file @
057b889a
...
@@ -70,7 +70,7 @@ behavior basp_broker::make_behavior() {
...
@@ -70,7 +70,7 @@ behavior basp_broker::make_behavior() {
ctx
.
hdl
=
msg
.
handle
;
ctx
.
hdl
=
msg
.
handle
;
ctx
.
handshake_data
=
none
;
ctx
.
handshake_data
=
none
;
ctx
.
state
=
await_client_handshake
;
ctx
.
state
=
await_client_handshake
;
init_handshake_as_sever
(
ctx
,
m_acceptors
[
msg
.
source
].
first
->
address
());
init_handshake_as_se
r
ver
(
ctx
,
m_acceptors
[
msg
.
source
].
first
->
address
());
},
},
// received from underlying broker implementation
// received from underlying broker implementation
[
=
](
const
connection_closed_msg
&
msg
)
{
[
=
](
const
connection_closed_msg
&
msg
)
{
...
@@ -648,7 +648,7 @@ void basp_broker::init_handshake_as_client(connection_context& ctx) {
...
@@ -648,7 +648,7 @@ void basp_broker::init_handshake_as_client(connection_context& ctx) {
configure_read
(
ctx
.
hdl
,
receive_policy
::
exactly
(
basp
::
header_size
));
configure_read
(
ctx
.
hdl
,
receive_policy
::
exactly
(
basp
::
header_size
));
}
}
void
basp_broker
::
init_handshake_as_sever
(
connection_context
&
ctx
,
void
basp_broker
::
init_handshake_as_se
r
ver
(
connection_context
&
ctx
,
actor_addr
addr
)
{
actor_addr
addr
)
{
CAF_LOG_TRACE
(
CAF_ARG
(
this
));
CAF_LOG_TRACE
(
CAF_ARG
(
this
));
CAF_REQUIRE
(
node
()
!=
invalid_node_id
);
CAF_REQUIRE
(
node
()
!=
invalid_node_id
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment