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
a80ca31a
Commit
a80ca31a
authored
Feb 21, 2022
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix formatting
parent
230fa863
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
10 deletions
+11
-10
libcaf_net/caf/net/handshake_worker.hpp
libcaf_net/caf/net/handshake_worker.hpp
+5
-5
libcaf_net/caf/net/stream_transport.hpp
libcaf_net/caf/net/stream_transport.hpp
+2
-1
libcaf_net/src/multiplexer.cpp
libcaf_net/src/multiplexer.cpp
+2
-2
libcaf_net/test/net/openssl_transport.cpp
libcaf_net/test/net/openssl_transport.cpp
+2
-2
No files found.
libcaf_net/caf/net/handshake_worker.hpp
View file @
a80ca31a
...
...
@@ -15,10 +15,10 @@ struct default_handshake_worker_factory {
OnError
abort
;
};
/// An connect worker calls an asynchronous `connect` callback until it
succeeds.
///
On success, the worker calls a factory object to transfer ownership of
///
socket and communication policy to the create the socket manager that takes
/// care of the established connection.
/// An connect worker calls an asynchronous `connect` callback until it
///
succeeds. On success, the worker calls a factory object to transfer
///
ownership of socket and communication policy to the create the socket
///
manager that takes
care of the established connection.
template
<
bool
IsServer
,
class
Socket
,
class
Policy
,
class
Factory
>
class
handshake_worker
:
public
socket_manager
{
public:
...
...
@@ -31,7 +31,7 @@ public:
using
write_result
=
typename
super
::
write_result
;
handshake_worker
(
Socket
handle
,
multiplexer
*
parent
,
Policy
policy
,
Factory
factory
)
Factory
factory
)
:
super
(
handle
,
parent
),
policy_
(
std
::
move
(
policy
)),
factory_
(
std
::
move
(
factory
))
{
...
...
libcaf_net/caf/net/stream_transport.hpp
View file @
a80ca31a
...
...
@@ -460,7 +460,8 @@ private:
/// Stores the current offset in `read_buf_`.
ptrdiff_t
offset_
=
0
;
/// Stores the offset in `read_buf_` since last calling `upper_layer_.consume`.
/// Stores the offset in `read_buf_` since last calling
/// `upper_layer_.consume`.
ptrdiff_t
delta_offset_
=
0
;
/// Caches incoming data.
...
...
libcaf_net/src/multiplexer.cpp
View file @
a80ca31a
...
...
@@ -158,7 +158,7 @@ operation multiplexer::mask_of(const socket_manager_ptr& mgr) {
auto
fd
=
mgr
->
handle
();
if
(
auto
i
=
updates_
.
find
(
fd
);
i
!=
updates_
.
end
())
return
to_operation
(
mgr
,
i
->
second
.
events
);
else
if
(
auto
index
=
index_of
(
mgr
);
index
!=
-
1
)
else
if
(
auto
index
=
index_of
(
mgr
);
index
!=
-
1
)
return
to_operation
(
mgr
,
pollset_
[
index
].
events
);
else
return
to_operation
(
mgr
,
std
::
nullopt
);
...
...
@@ -281,7 +281,7 @@ bool multiplexer::poll_once(bool blocking) {
// is allowed to modify pollset_ and managers_. Since this may very well
// mess with the for loop below, we process this handler first.
auto
mgr
=
managers_
[
0
];
handle
(
mgr
,
pollset_
[
0
].
events
,
revents
);
handle
(
mgr
,
pollset_
[
0
].
events
,
revents
);
--
presult
;
}
for
(
size_t
i
=
1
;
i
<
pollset_
.
size
()
&&
presult
>
0
;
++
i
)
{
...
...
libcaf_net/test/net/openssl_transport.cpp
View file @
a80ca31a
...
...
@@ -43,7 +43,7 @@ using byte_buffer_ptr = std::shared_ptr<byte_buffer>;
struct
fixture
:
host_fixture
{
using
byte_buffer_ptr
=
std
::
shared_ptr
<
byte_buffer
>
;
fixture
(){
fixture
()
{
multiplexer
::
block_sigpipe
();
OPENSSL_init_ssl
(
OPENSSL_INIT_SSL_DEFAULT
,
nullptr
);
// Make a directory name with 8 random (hex) character suffix.
...
...
@@ -174,7 +174,7 @@ void dummy_tls_server(stream_socket fd, std::string cert_file,
if
(
f
.
accept
(
fd
)
<=
0
)
{
std
::
cerr
<<
"*** accept failed: "
<<
ssl
::
fetch_error_str
();
return
;
}
}
// Do some ping-pong messaging.
for
(
int
i
=
0
;
i
<
4
;
++
i
)
{
byte_buffer
buf
;
...
...
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