]> git.eshelyaron.com Git - emacs.git/commitdiff
Improve error reporting for DOC file problems
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 12 Sep 2019 06:45:32 +0000 (23:45 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 12 Sep 2019 06:46:58 +0000 (23:46 -0700)
* src/doc.c (get_doc_string): Report all serious errors
when DOC cannot be opened, not just fd-exhaustion errors.

src/doc.c

index 247be79adafe8910c0fc1805ab4e55779afa51bd..b06b87c6114b57ba4a91b455f437ff0888906322 100644 (file)
--- a/src/doc.c
+++ b/src/doc.c
@@ -136,7 +136,7 @@ get_doc_string (Lisp_Object filepos, bool unibyte, bool definition)
        }
       if (fd < 0)
        {
-         if (errno == EMFILE || errno == ENFILE)
+         if (errno != ENOENT && errno != ENOTDIR)
            report_file_error ("Read error on documentation file", file);
 
          SAFE_FREE ();