--- a/mpd2src/fiforeader.cpp
+++ b/mpd2src/fiforeader.cpp
@@ -66,8 +66,20 @@
     return true;
 }
 
+void FifoReader::close()
+{
+    LOGDEB("FifoReader::close" << endl);
+    if (m_fd > 0) {
+        ::close(m_fd);
+        m_fd = -1;
+    }
+}
+
 const unsigned char *FifoReader::data(size_t size, ssize_t &nread)
 {
+    if (m_fd < 0) // nothing to read from
+        return 0;
+
     nread = 0;
 
     //LOGDEB("FifoReader: data " << size << " bytes. blocking " << m_blocking