Index: src/mgr/filemgr.cpp =================================================================== --- src/mgr/filemgr.cpp (revision 2457) +++ src/mgr/filemgr.cpp (working copy) @@ -136,7 +136,11 @@ long FileDesc::read(void *buf, long count) { - return ::read(getFd(), buf, count); + int fd = getFd(); + if (fd < 0) { + return 0; + } + return ::read(fd, buf, count); }