From e63304b745e5f27ce84e74b1d0766174437db5ce Mon Sep 17 00:00:00 2001 From: Dave Love Date: Wed, 30 Oct 2002 19:15:17 +0000 Subject: [PATCH] (Fload) : Close fd. --- src/lread.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/lread.c b/src/lread.c index 5dc3cc9346e..c60064bc7a3 100644 --- a/src/lread.c +++ b/src/lread.c @@ -793,8 +793,12 @@ Return t if file exists. */) { safe_p = 0; if (!load_dangerous_libraries) - error ("File `%s' was not compiled in Emacs", - SDATA (found)); + { + if (fd >= 0) + emacs_close (fd); + error ("File `%s' was not compiled in Emacs", + SDATA (found)); + } else if (!NILP (nomessage)) message_with_string ("File `%s' not compiled in Emacs", found, 1); } -- 2.39.2