Commit c6da1a38 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 868f88cd
......@@ -255,13 +255,12 @@ tuple<Conn*, error> WCFS::connect(Tid at) {
return make_tuple(wconn, nil);
}
// XXX Conn::close
#if 0
# close releases resources associated with wconn.
# XXX what happens to file mmappings?
@func(Conn)
def close(wconn):
wconn._wlink.close()
// close releases resources associated with wconn.
// XXX what happens to file mmappings?
error Conn::close(wconn) {
Conn &wconn = *this;
wconn._wlink.close();
wconn._pinCancel()
try:
wconn._pinWG.wait()
......@@ -269,9 +268,9 @@ def close(wconn):
if e is not context.canceled:
raise
# close all files - both that have no mappings and that still have opened mappings.
# XXX after file is closed mappings continue to survive, but we can no
# longer maintain consistent view.
// close all files - both that have no mappings and that still have opened mappings.
// XXX after file is closed mappings continue to survive, but we can no
// longer maintain consistent view.
with wconn._filemu:
for f in wconn._filetab.values():
f.headf.close()
......@@ -280,7 +279,7 @@ def close(wconn):
# XXX stop watching f
wconn._filetab = None
#endif
}
// _pinner receives pin messages from wcfs and adjusts wconn mappings.
void Conn::_pinner(IContext *ctx) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment