From e72eef421b75516e0447e4a06419d1a7aba4d853 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 25 Nov 2014 12:29:55 +0100 Subject: lib/nfs/FileReader: clean up on disconnect Avoids crash because Close() invokes a call on a destructed NfsConnection. --- src/lib/nfs/FileReader.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/lib/nfs/FileReader.cxx b/src/lib/nfs/FileReader.cxx index 455165bbd..1b80f2c86 100644 --- a/src/lib/nfs/FileReader.cxx +++ b/src/lib/nfs/FileReader.cxx @@ -186,7 +186,7 @@ NfsFileReader::OnNfsConnectionDisconnected(const Error &error) { assert(state > State::MOUNT); - state = State::INITIAL; + CancelOrClose(); Error copy; copy.Set(error); -- cgit v1.2.3