]> git.eshelyaron.com Git - emacs.git/commitdiff
Improve checks for recent "File exists" fixup
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 13 Oct 2022 16:33:46 +0000 (09:33 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 13 Oct 2022 16:34:13 +0000 (09:34 -0700)
* src/fileio.c (Finsert_file_contents): Add an assertion (bug#42431).

src/fileio.c

index 49553f3c91f3f86722fd45f1502ba36fe72188e6..b9a57dd5800c9908c11e703de6ba8c420f70e35c 100644 (file)
@@ -5003,6 +5003,7 @@ by calling `format-decode', which see.  */)
   if (save_errno != 0)
     {
       /* Signal an error if visiting a file that could not be opened.  */
+      eassert (!NILP (visit) && NILP (handler));
       report_file_errno ("Opening input file", orig_filename, save_errno);
     }