Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
C
capnproto
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
capnproto
Commits
40107f9a
Commit
40107f9a
authored
Jan 09, 2016
by
Kenton Varda
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #278 from dwrensha/typo
Fix some outdated comments and error messages.
parents
74c91604
b48861aa
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
9 deletions
+10
-9
capability.h
c++/src/capnp/capability.h
+1
-1
rpc-twoparty.h
c++/src/capnp/rpc-twoparty.h
+4
-3
rpc.c++
c++/src/capnp/rpc.c++
+4
-4
rpc.capnp
c++/src/capnp/rpc.capnp
+1
-1
No files found.
c++/src/capnp/capability.h
View file @
40107f9a
...
...
@@ -341,7 +341,7 @@ protected:
// The effect of this method is undefined if:
// - No capability client has been created pointing to this object. (This is always the case in
// the server's constructor.)
// - The capability client pointing at this object has been dest
or
yed. (This is always the case
// - The capability client pointing at this object has been dest
ro
yed. (This is always the case
// in the server's destructor.)
// - Multiple capability clients have been created around the same server (possible if the server
// is refcounted, which is not recommended since the client itself provides refcounting).
...
...
c++/src/capnp/rpc-twoparty.h
View file @
40107f9a
...
...
@@ -90,8 +90,9 @@ private:
class
FulfillerDisposer
:
public
kj
::
Disposer
{
// Hack: TwoPartyVatNetwork is both a VatNetwork and a VatNetwork::Connection. When the RPC
// system detects (or initiates) a disconnection, it drops its reference to the Connection.
// When all references have been dropped, then we want onDrained() to fire. So we hand out
// Own<Connection>s with this disposer attached, so that we can detect when they are dropped.
// When all references have been dropped, then we want disconnectPromise to be fulfilled.
// So we hand out Own<Connection>s with this disposer attached, so that we can detect when
// they are dropped.
public
:
mutable
kj
::
Own
<
kj
::
PromiseFulfiller
<
void
>>
fulfiller
;
...
...
@@ -102,7 +103,7 @@ private:
FulfillerDisposer
disconnectFulfiller
;
kj
::
Own
<
TwoPartyVatNetworkBase
::
Connection
>
asConnection
();
// Returns a pointer to this with the disposer set to d
rained
Fulfiller.
// Returns a pointer to this with the disposer set to d
isconnect
Fulfiller.
// implements Connection -----------------------------------------------------
...
...
c++/src/capnp/rpc.c++
View file @
40107f9a
...
...
@@ -928,7 +928,7 @@ private:
message
->
send
();
}
cap
=
replacement
->
addRef
(
);
cap
=
kj
::
mv
(
replacement
);
isResolved
=
true
;
}
};
...
...
@@ -1275,7 +1275,7 @@ private:
// If we're still awaiting a return, then this request is being canceled, and we're going
// to ignore any capabilities in the return message, so set releaseResultCaps true. If we
// already received the return, then we've already built local proxies for the caps and
// will send Release messages when those are dest
or
yed.
// will send Release messages when those are dest
ro
yed.
builder
.
setReleaseResultCaps
(
question
.
isAwaitingReturn
);
message
->
send
();
}
...
...
@@ -2390,11 +2390,11 @@ private:
KJ_IF_MAYBE
(
response
,
answer
->
redirectedResults
)
{
questionRef
->
fulfill
(
kj
::
mv
(
*
response
));
}
else
{
KJ_FAIL_REQUIRE
(
"`Return.takeFromOther
Answer
` referenced a call that did not "
KJ_FAIL_REQUIRE
(
"`Return.takeFromOther
Question
` referenced a call that did not "
"use `sendResultsTo.yourself`."
)
{
return
;
}
}
}
else
{
KJ_FAIL_REQUIRE
(
"`Return.takeFromOther
Answer
` had invalid answer ID."
)
{
return
;
}
KJ_FAIL_REQUIRE
(
"`Return.takeFromOther
Question
` had invalid answer ID."
)
{
return
;
}
}
break
;
...
...
c++/src/capnp/rpc.capnp
View file @
40107f9a
...
...
@@ -431,7 +431,7 @@ struct Call {
# Don't actually return the results to the sender. Instead, hold on to them and await
# instructions from the sender regarding what to do with them. In particular, the sender
# may subsequently send a `Return` for some other call (which the receiver had previously made
# to the sender) with `takeFromOther
Answer
` set. The results from this call are then used
# to the sender) with `takeFromOther
Question
` set. The results from this call are then used
# as the results of the other call.
#
# When `yourself` is used, the receiver must still send a `Return` for the call, but sets the
...
...
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