changeset 7533:62e3e25bc8f6

(Fbacktrace): Properly nest parentheses. (Fbacktrace_frame): Don't bomb on invalid frame number.
author Karl Heuer <kwzh@gnu.org>
date Tue, 17 May 1994 22:58:29 +0000
parents 996928472982
children 9b82dae27c01
files src/eval.c
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/eval.c	Tue May 17 19:51:54 1994 +0000
+++ b/src/eval.c	Tue May 17 22:58:29 1994 +0000
@@ -2408,6 +2408,7 @@
       if (backlist->nargs == UNEVALLED)
 	{
 	  Fprin1 (Fcons (*backlist->function, *backlist->args), Qnil);
+	  write_string ("\n", -1);
 	}
       else
 	{
@@ -2432,8 +2433,8 @@
 		  Fprin1 (backlist->args[i], Qnil);
 		}
 	    }
+	  write_string (")\n", -1);
 	}
-      write_string (")\n", -1);
       backlist = backlist->next;
     }
 
@@ -2462,7 +2463,7 @@
   CHECK_NATNUM (nframes, 0);
 
   /* Find the frame requested.  */
-  for (i = 0; i < XFASTINT (nframes); i++)
+  for (i = 0; backlist && i < XFASTINT (nframes); i++)
     backlist = backlist->next;
 
   if (!backlist)