lib/nfs/Connection: pass std::exception_ptr by value
This commit is contained in:
parent
2b0275a1c8
commit
f5127686fe
|
@ -589,7 +589,7 @@ NfsConnection::BroadcastMountSuccess() noexcept
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
NfsConnection::BroadcastMountError(std::exception_ptr &&e) noexcept
|
NfsConnection::BroadcastMountError(std::exception_ptr e) noexcept
|
||||||
{
|
{
|
||||||
assert(GetEventLoop().IsInside());
|
assert(GetEventLoop().IsInside());
|
||||||
|
|
||||||
|
@ -603,7 +603,7 @@ NfsConnection::BroadcastMountError(std::exception_ptr &&e) noexcept
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
NfsConnection::BroadcastError(std::exception_ptr &&e) noexcept
|
NfsConnection::BroadcastError(std::exception_ptr e) noexcept
|
||||||
{
|
{
|
||||||
assert(GetEventLoop().IsInside());
|
assert(GetEventLoop().IsInside());
|
||||||
|
|
||||||
|
|
|
@ -186,7 +186,7 @@ public:
|
||||||
void CancelAndClose(struct nfsfh *fh, NfsCallback &callback) noexcept;
|
void CancelAndClose(struct nfsfh *fh, NfsCallback &callback) noexcept;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void OnNfsConnectionError(std::exception_ptr &&e) noexcept = 0;
|
virtual void OnNfsConnectionError(std::exception_ptr e) noexcept = 0;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void DestroyContext() noexcept;
|
void DestroyContext() noexcept;
|
||||||
|
@ -203,8 +203,8 @@ private:
|
||||||
|
|
||||||
void MountInternal();
|
void MountInternal();
|
||||||
void BroadcastMountSuccess() noexcept;
|
void BroadcastMountSuccess() noexcept;
|
||||||
void BroadcastMountError(std::exception_ptr &&e) noexcept;
|
void BroadcastMountError(std::exception_ptr e) noexcept;
|
||||||
void BroadcastError(std::exception_ptr &&e) noexcept;
|
void BroadcastError(std::exception_ptr e) noexcept;
|
||||||
|
|
||||||
static void MountCallback(int status, nfs_context *nfs, void *data,
|
static void MountCallback(int status, nfs_context *nfs, void *data,
|
||||||
void *private_data) noexcept;
|
void *private_data) noexcept;
|
||||||
|
|
|
@ -27,11 +27,11 @@ public:
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
/* virtual methods from NfsConnection */
|
/* virtual methods from NfsConnection */
|
||||||
void OnNfsConnectionError(std::exception_ptr &&e) noexcept override;
|
void OnNfsConnectionError(std::exception_ptr e) noexcept override;
|
||||||
};
|
};
|
||||||
|
|
||||||
void
|
void
|
||||||
NfsManager::ManagedConnection::OnNfsConnectionError(std::exception_ptr &&e) noexcept
|
NfsManager::ManagedConnection::OnNfsConnectionError(std::exception_ptr e) noexcept
|
||||||
{
|
{
|
||||||
FmtError(nfs_domain, "NFS error on '{}:{}': {}",
|
FmtError(nfs_domain, "NFS error on '{}:{}': {}",
|
||||||
GetServer(), GetExportName(), e);
|
GetServer(), GetExportName(), e);
|
||||||
|
|
Loading…
Reference in New Issue