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
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
8045d1e3
Commit
8045d1e3
authored
Oct 25, 2019
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
d80f5e07
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
wcfs/internal/wcfs_virtmem.cpp
wcfs/internal/wcfs_virtmem.cpp
+12
-3
No files found.
wcfs/internal/wcfs_virtmem.cpp
View file @
8045d1e3
...
...
@@ -410,8 +410,13 @@ void WatchLink::_closeTX() {
// ask wcfs to close its tx & rx sides; close(wcfs.tx) wakes up
// _serveRX on client (= on us). The connection can be already closed
// by wcfs - so ignore errors when sending bye.
(
void
)
wlink
.
_send
(
1
,
"bye"
);
wlink
.
_wtx
.
close
();
// XXX ._f.closeTX() ? XXX err
(
void
)
wlink
.
_send
(
1
,
"bye"
);
// XXX stream ok?
// XXX vvv should be ~ shutdown(TX, wlink._f), however shutdown does
// not work for non-socket file descriptors. And even if we dup link
// fd, and close only one used for TX, peer's RX will still be blocked
// ad fds are referring to one file object which stays in opened
// state. So just use ^^^ "bye" as "TX closed" message.
// wlink._wtx.close();
});
}
...
...
@@ -420,6 +425,7 @@ error WatchLink::close() {
WatchLink
&
wlink
=
*
this
;
wlink
.
_closeTX
();
#if 0
wlink._serveCancel();
// XXX we can get stuck here if wcfs does not behave as we want.
// XXX in particular if there is a silly - e.g. syntax or type error in
...
...
@@ -431,8 +437,11 @@ error WatchLink::close() {
// canceled is expected and ok
if (err == context.canceled)
err = nil;
#else
error
err
=
nil
;
#endif
error
err2
=
wlink
.
_
wrx
.
close
();
// XXX err
;
error
err2
=
wlink
.
_
f
.
close
()
;
if
(
err
==
nil
)
err
=
err2
;
...
...
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