]> git.eshelyaron.com Git - emacs.git/commitdiff
(Fload) <!load_dangerous_libraries>: Don't leak fd.
authorDave Love <fx@gnu.org>
Thu, 18 Jul 2002 16:30:48 +0000 (16:30 +0000)
committerDave Love <fx@gnu.org>
Thu, 18 Jul 2002 16:30:48 +0000 (16:30 +0000)
<version == 20>: Refuse to load.

src/ChangeLog
src/lread.c

index d4aaeb3d54861cfdbf69e6af9e016d5080a390d5..6b777088a12dbe7f0804e3ebd6270168c95ab677 100644 (file)
@@ -1,3 +1,8 @@
+2002-07-18  Dave Love  <fx@gnu.org>
+
+       * lread.c (Fload) <!load_dangerous_libraries>: Don't leak fd.
+       <version == 20>: Refuse to load.
+
 2002-07-17  Dave Love  <fx@gnu.org>
 
        * fns.c: Move coding.h.
index d2d55be637a618880e9ebe9a01fffb9aa4a3b82c..b4dc71514d98253395c4d2e272bfa2c34cd7bac2 100644 (file)
@@ -758,8 +758,11 @@ Return t if file exists.  */)
            {
              safe_p = 0;
              if (!load_dangerous_libraries)
-               error ("File `%s' was not compiled in Emacs",
-                      XSTRING (found)->data);
+               {
+                 emacs_close (fd);
+                 error ("File `%s' was not compiled in Emacs",
+                        XSTRING (found)->data);
+               }
              else if (!NILP (nomessage))
                message_with_string ("File `%s' not compiled in Emacs", found, 1);
            }
@@ -778,9 +781,15 @@ Return t if file exists.  */)
 
              if (fd >= 0)
                emacs_close (fd);
+             /* load-with-code-conversion currently fails with
+                emacs-mule non-ASCII doc strings.  */
+             error ("Can't currently load Emacs 20/1-compiled files: %s",
+                    XSTRING (found)->data);
+#if 0
              val = call4 (intern ("load-with-code-conversion"), found, file,
                           NILP (noerror) ? Qnil : Qt,
                           NILP (nomessage) ? Qnil : Qt);
+#endif
              return unbind_to (count, val);
            }