diff options
Diffstat (limited to '')
-rw-r--r-- | src/lib/nfs/Connection.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/nfs/Connection.cxx b/src/lib/nfs/Connection.cxx index a2f0cbb45..a99b845b9 100644 --- a/src/lib/nfs/Connection.cxx +++ b/src/lib/nfs/Connection.cxx @@ -223,7 +223,9 @@ NfsConnection::DestroyContext() { assert(context != nullptr); - SocketMonitor::Cancel(); + if (SocketMonitor::IsDefined()) + SocketMonitor::Cancel(); + nfs_destroy_context(context); context = nullptr; } |