]> git.eshelyaron.com Git - emacs.git/commitdiff
* lread.c (Fload): Avoid uninitialized warning.
authorAndreas Schwab <schwab@linux-m68k.org>
Sat, 20 Jul 2013 08:25:46 +0000 (10:25 +0200)
committerAndreas Schwab <schwab@linux-m68k.org>
Sat, 20 Jul 2013 08:25:46 +0000 (10:25 +0200)
src/ChangeLog
src/lread.c

index a63e441dcb2d02f0e37031a6c278c38422aaf7ad..712fc2bc3b58a1e497d1fe55fd69d0ccb7e89516 100644 (file)
@@ -1,3 +1,7 @@
+2013-07-20  Andreas Schwab  <schwab@linux-m68k.org>
+
+       * lread.c (Fload): Avoid uninitialized warning.
+
 2013-07-19  Paul Eggert  <eggert@cs.ucla.edu>
 
        Fix some minor file descriptor leaks and related glitches.
index 146543a99fd7a5a6b2f50154a06eeb115636f89a..e701338da31ea409c73c149b50495302a3b0e54e 100644 (file)
@@ -1044,7 +1044,7 @@ Return t if the file exists and loads successfully.  */)
 {
   FILE *stream;
   int fd;
-  int fd_index;
+  int fd_index = 0;
   ptrdiff_t count = SPECPDL_INDEX ();
   struct gcpro gcpro1, gcpro2, gcpro3;
   Lisp_Object found, efound, hist_file_name;
@@ -1175,7 +1175,7 @@ Return t if the file exists and loads successfully.  */)
 #endif
     }
 
-  if (0 <= fd)
+  if (fd >= 0)
     {
       fd_index = SPECPDL_INDEX ();
       record_unwind_protect_int (close_file_unwind, fd);