diff --git a/src/lib/nfs/Connection.cxx b/src/lib/nfs/Connection.cxx index 6d24decc9..d6910a7a5 100644 --- a/src/lib/nfs/Connection.cxx +++ b/src/lib/nfs/Connection.cxx @@ -589,7 +589,7 @@ NfsConnection::BroadcastMountSuccess() noexcept } void -NfsConnection::BroadcastMountError(std::exception_ptr &&e) noexcept +NfsConnection::BroadcastMountError(std::exception_ptr e) noexcept { assert(GetEventLoop().IsInside()); @@ -603,7 +603,7 @@ NfsConnection::BroadcastMountError(std::exception_ptr &&e) noexcept } void -NfsConnection::BroadcastError(std::exception_ptr &&e) noexcept +NfsConnection::BroadcastError(std::exception_ptr e) noexcept { assert(GetEventLoop().IsInside()); diff --git a/src/lib/nfs/Connection.hxx b/src/lib/nfs/Connection.hxx index 814209890..1debc0a05 100644 --- a/src/lib/nfs/Connection.hxx +++ b/src/lib/nfs/Connection.hxx @@ -186,7 +186,7 @@ public: void CancelAndClose(struct nfsfh *fh, NfsCallback &callback) noexcept; protected: - virtual void OnNfsConnectionError(std::exception_ptr &&e) noexcept = 0; + virtual void OnNfsConnectionError(std::exception_ptr e) noexcept = 0; private: void DestroyContext() noexcept; @@ -203,8 +203,8 @@ private: void MountInternal(); void BroadcastMountSuccess() noexcept; - void BroadcastMountError(std::exception_ptr &&e) noexcept; - void BroadcastError(std::exception_ptr &&e) noexcept; + void BroadcastMountError(std::exception_ptr e) noexcept; + void BroadcastError(std::exception_ptr e) noexcept; static void MountCallback(int status, nfs_context *nfs, void *data, void *private_data) noexcept; diff --git a/src/lib/nfs/Manager.cxx b/src/lib/nfs/Manager.cxx index 6cab13390..07cc9766d 100644 --- a/src/lib/nfs/Manager.cxx +++ b/src/lib/nfs/Manager.cxx @@ -27,11 +27,11 @@ public: protected: /* virtual methods from NfsConnection */ - void OnNfsConnectionError(std::exception_ptr &&e) noexcept override; + void OnNfsConnectionError(std::exception_ptr e) noexcept override; }; void -NfsManager::ManagedConnection::OnNfsConnectionError(std::exception_ptr &&e) noexcept +NfsManager::ManagedConnection::OnNfsConnectionError(std::exception_ptr e) noexcept { FmtError(nfs_domain, "NFS error on '{}:{}': {}", GetServer(), GetExportName(), e);