]> git.eshelyaron.com Git - emacs.git/commitdiff
(Fminibuffer_complete_and_exit): Avoid dangerous side effects in NILP argument.
authorKen Raeburn <raeburn@raeburn.org>
Tue, 6 Dec 2005 07:39:57 +0000 (07:39 +0000)
committerKen Raeburn <raeburn@raeburn.org>
Tue, 6 Dec 2005 07:39:57 +0000 (07:39 +0000)
src/minibuf.c

index e7df7bd01536288b453381e4fa461098eb4bc20c..76529bf86e61f5fd07f3097d32c8b57c7c8cdb04 100644 (file)
@@ -2116,16 +2116,17 @@ a repetition of this command will exit.  */)
      ()
 {
   register int i;
-  Lisp_Object val;
+  Lisp_Object val, tem;
 
   /* Allow user to specify null string */
   if (XINT (Fminibuffer_prompt_end ()) == ZV)
     goto exit;
 
   val = Fminibuffer_contents ();
-  if (!NILP (Ftest_completion (val,
-                              Vminibuffer_completion_table,
-                              Vminibuffer_completion_predicate)))
+  tem = Ftest_completion (val,
+                         Vminibuffer_completion_table,
+                         Vminibuffer_completion_predicate);
+  if (!NILP (tem))
     {
       if (completion_ignore_case)
        { /* Fixup case of the field, if necessary. */