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
2e607276
Commit
2e607276
authored
Mar 10, 2020
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
1519b8ae
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
wcfs/client/wcfs_watchlink.cpp
wcfs/client/wcfs_watchlink.cpp
+1
-5
No files found.
wcfs/client/wcfs_watchlink.cpp
View file @
2e607276
...
...
@@ -269,8 +269,6 @@ pair</*reply*/string, error> _WatchLink::sendReq(context::Context ctx, const str
_WatchLink
&
wlink
=
*
this
;
xerr
::
Contextf
E
(
"%s: sendReq"
,
v
(
wlink
));
// XXX + streamID
//printf("wlink sendReq '%s'\n", v(req));
rxPkt
rx
;
bool
ok
;
chan
<
rxPkt
>
rxq
;
error
err
;
...
...
@@ -278,19 +276,16 @@ pair</*reply*/string, error> _WatchLink::sendReq(context::Context ctx, const str
if
(
err
!=
nil
)
return
make_pair
(
""
,
E
(
err
));
//printf("sendReq: wait ...\n");
int
_
=
select
({
ctx
->
done
().
recvs
(),
// 0
rxq
.
recvs
(
&
rx
,
&
ok
),
// 1
});
//printf("sendReq: woken up #%d\n", _);
if
(
_
==
0
)
return
make_pair
(
""
,
E
(
ctx
->
err
()));
if
(
!
ok
)
return
make_pair
(
""
,
E
(
io
::
ErrUnexpectedEOF
));
// XXX error ok?
string
reply
=
rx
.
to_string
();
//printf("sendReq: reply='%s'\n", v(reply));
return
make_pair
(
reply
,
nil
);
}
...
...
@@ -354,6 +349,7 @@ error _WatchLink::_write(const string &pkt) {
});
trace
(
"C: watch : tx:
\"
%s
\"
"
,
v
(
pkt
));
int
n
;
error
err
;
tie
(
n
,
err
)
=
wlink
.
_f
->
write
(
pkt
.
c_str
(),
pkt
.
size
());
...
...
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