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
bb8587da
Commit
bb8587da
authored
4 years ago
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
d29b0dae
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
5 additions
and
8 deletions
+5
-8
wcfs/client/_wcfs.pyx
wcfs/client/_wcfs.pyx
+1
-0
wcfs/client/wcfs.cpp
wcfs/client/wcfs.cpp
+1
-1
wcfs/client/wcfs_misc.h
wcfs/client/wcfs_misc.h
+0
-4
wcfs/client/wcfs_watchlink.cpp
wcfs/client/wcfs_watchlink.cpp
+1
-1
wcfs/wcfs_test.py
wcfs/wcfs_test.py
+2
-2
No files found.
wcfs/client/_wcfs.pyx
View file @
bb8587da
...
@@ -267,6 +267,7 @@ cdef object pyerr(error err):
...
@@ -267,6 +267,7 @@ cdef object pyerr(error err):
return
None
return
None
# XXX support for other errors? is it good idea?
# XXX support for other errors? is it good idea?
# XXX -> errors.Is ?
if
err
.
eq
(
context
.
canceled
):
if
err
.
eq
(
context
.
canceled
):
return
pycontext
.
canceled
return
pycontext
.
canceled
if
err
.
eq
(
context
.
deadlineExceeded
):
if
err
.
eq
(
context
.
deadlineExceeded
):
...
...
This diff is collapsed.
Click to expand it.
wcfs/client/wcfs.cpp
View file @
bb8587da
...
@@ -130,7 +130,7 @@ error _Conn::close() {
...
@@ -130,7 +130,7 @@ error _Conn::close() {
reterr1
(
err
);
reterr1
(
err
);
wconn
.
_pinCancel
();
wconn
.
_pinCancel
();
err
=
wconn
.
_pinWG
->
wait
();
err
=
wconn
.
_pinWG
->
wait
();
if
(
err
!=
context
::
canceled
)
// canceled - ok XXX check ok?
if
(
!
errors
::
Is
(
err
,
context
::
canceled
))
// canceled - ok
reterr1
(
err
);
reterr1
(
err
);
// close all files - both that have no mappings and that still have opened mappings.
// close all files - both that have no mappings and that still have opened mappings.
...
...
This diff is collapsed.
Click to expand it.
wcfs/client/wcfs_misc.h
View file @
bb8587da
...
@@ -51,10 +51,6 @@ using std::tie;
...
@@ -51,10 +51,6 @@ using std::tie;
using
std
::
vector
;
using
std
::
vector
;
// nil is synonym for nullptr and NULL. XXX -> pygolang
const
nullptr_t
nil
=
nullptr
;
// io:: XXX -> pygolang
// io:: XXX -> pygolang
namespace
io
{
namespace
io
{
...
...
This diff is collapsed.
Click to expand it.
wcfs/client/wcfs_watchlink.cpp
View file @
bb8587da
...
@@ -101,7 +101,7 @@ error _WatchLink::close() {
...
@@ -101,7 +101,7 @@ error _WatchLink::close() {
// XXX -> we now have `kill -QUIT` to wcfs.go on test timeout - remove ^^^ comments?
// XXX -> we now have `kill -QUIT` to wcfs.go on test timeout - remove ^^^ comments?
error
err2
=
wlink
.
_serveWG
->
wait
();
error
err2
=
wlink
.
_serveWG
->
wait
();
// canceled is expected and ok
// canceled is expected and ok
if
(
err
2
==
context
::
canceled
)
// FIXME -> errors.Cause(err2) | errors.Is(err2, context::canceled
)
if
(
err
ors
.
Is
(
err2
,
context
::
canceled
)
)
err2
=
nil
;
err2
=
nil
;
error
err3
=
wlink
.
_f
->
close
();
error
err3
=
wlink
.
_f
->
close
();
...
...
This diff is collapsed.
Click to expand it.
wcfs/wcfs_test.py
View file @
bb8587da
...
@@ -948,7 +948,7 @@ def doCheckingPin(f, pinokByWLink, pinfunc=None): # -> []event(str)
...
@@ -948,7 +948,7 @@ def doCheckingPin(f, pinokByWLink, pinfunc=None): # -> []event(str)
try
:
try
:
req
=
wlink
.
recvReq
(
ctx
)
req
=
wlink
.
recvReq
(
ctx
)
except
Exception
as
e
:
except
Exception
as
e
:
if
e
is
context
.
canceled
:
if
e
is
context
.
canceled
:
# XXX -> errors.Is
return
# cancel is expected after f completes
return
# cancel is expected after f completes
raise
raise
...
@@ -1984,7 +1984,7 @@ def procwait_(ctx, proc): # -> ok
...
@@ -1984,7 +1984,7 @@ def procwait_(ctx, proc): # -> ok
try
:
try
:
procwait
(
ctx
,
proc
)
procwait
(
ctx
,
proc
)
except
Exception
as
e
:
except
Exception
as
e
:
if
e
in
(
context
.
canceled
,
context
.
deadlineExceeded
):
if
e
in
(
context
.
canceled
,
context
.
deadlineExceeded
):
# XXX -> errors.Is
return
False
return
False
raise
raise
return
True
return
True
...
...
This diff is collapsed.
Click to expand it.
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