[Yunq] Release server cap on destructor.
This commit is contained in:
parent
43d7bfa7ad
commit
96a2f74e14
14 changed files with 123 additions and 8 deletions
|
|
@ -29,6 +29,12 @@ void VoyageursServerBaseThreadBootstrap(void* server_base) {
|
|||
((VoyageursServerBase*)server_base)->ServerThread();
|
||||
}
|
||||
|
||||
VoyageursServerBase::~VoyageursServerBase() {
|
||||
if (endpoint_ != 0) {
|
||||
check(ZCapRelease(endpoint_));
|
||||
}
|
||||
}
|
||||
|
||||
glcr::ErrorOr<VoyageursClient> VoyageursServerBase::CreateClient() {
|
||||
uint64_t client_cap;
|
||||
RET_ERR(ZCapDuplicate(endpoint_, ~(kZionPerm_Read), &client_cap));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue