# HG changeset patch # User Dave Love # Date 1036005317 0 # Node ID cae822515e00978432d51ca90559a8383074e85b # Parent b61109579f17ef841c5ed2d34ca01c27e491ee6a (Fload) : Close fd. diff -r b61109579f17 -r cae822515e00 src/lread.c --- a/src/lread.c Wed Oct 30 19:13:10 2002 +0000 +++ b/src/lread.c Wed Oct 30 19:15:17 2002 +0000 @@ -793,8 +793,12 @@ { 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); }