Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Joshua
wendelin.core
Commits
68871b72
Commit
68871b72
authored
Mar 10, 2020
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
a631c5ab
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
wcfs/client/wcfs_watchlink.cpp
wcfs/client/wcfs_watchlink.cpp
+4
-5
No files found.
wcfs/client/wcfs_watchlink.cpp
View file @
68871b72
...
@@ -168,8 +168,8 @@ error _WatchLink::_serveRX(context::Context ctx) {
...
@@ -168,8 +168,8 @@ error _WatchLink::_serveRX(context::Context ctx) {
if
(
pkt
.
stream
==
0
)
{
// control/fatal message from wcfs
if
(
pkt
.
stream
==
0
)
{
// control/fatal message from wcfs
log
::
Errorf
(
"C: watch : rx fatal: %s
\n
"
,
v
(
l
));
log
::
Errorf
(
"C: watch : rx fatal: %s
\n
"
,
v
(
l
));
wlink
.
fatalv
.
push_back
(
pkt
.
to_string
());
wlink
.
fatalv
.
push_back
(
pkt
.
to_string
());
// XXX stub -> errorq?
return
E
(
ErrLinkDown
);
// XXX correct
error
continue
;
// wcfs should close link after
error
}
}
bool
reply
=
(
pkt
.
stream
%
2
!=
0
);
bool
reply
=
(
pkt
.
stream
%
2
!=
0
);
...
@@ -184,9 +184,8 @@ error _WatchLink::_serveRX(context::Context ctx) {
...
@@ -184,9 +184,8 @@ error _WatchLink::_serveRX(context::Context ctx) {
wlink
.
_rxmu
.
unlock
();
wlink
.
_rxmu
.
unlock
();
if
(
!
ok
)
{
if
(
!
ok
)
{
// wcfs sent reply on unexpected stream -> shutdown wlink.
// wcfs sent reply on unexpected stream -> shutdown wlink.
// XXX down.
log
::
Errorf
(
"%s: .%lu: wcfs sent reply on unexpected stream"
,
v
(
wlink
),
pkt
.
stream
);
log
::
Errorf
(
"%s: .%lu: wcfs sent reply on unexpected stream"
,
v
(
wlink
),
pkt
.
stream
);
return
E
rrLinkDown
;
// XXX correct error
return
E
(
ErrLinkDown
);
}
}
int
_
=
select
({
int
_
=
select
({
ctx
->
done
().
recvs
(),
// 0
ctx
->
done
().
recvs
(),
// 0
...
@@ -203,7 +202,7 @@ error _WatchLink::_serveRX(context::Context ctx) {
...
@@ -203,7 +202,7 @@ error _WatchLink::_serveRX(context::Context ctx) {
wlink
.
_rxmu
.
unlock
();
wlink
.
_rxmu
.
unlock
();
// wcfs request on already used stream
// wcfs request on already used stream
log
::
Errorf
(
"%s: .%lu: wcfs sent request on already used stream"
,
v
(
wlink
),
pkt
.
stream
);
log
::
Errorf
(
"%s: .%lu: wcfs sent request on already used stream"
,
v
(
wlink
),
pkt
.
stream
);
return
E
rrLinkDown
;
// XXX correct error
return
E
(
ErrLinkDown
);
}
}
wlink
.
_accepted
.
insert
(
pkt
.
stream
);
wlink
.
_accepted
.
insert
(
pkt
.
stream
);
wlink
.
_rxmu
.
unlock
();
wlink
.
_rxmu
.
unlock
();
...
...
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