From 8d7e15b35884a1e272beb7d3a7de7c6a4d446065 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Henrik=20Grubbstr=C3=B6m=20=28Grubba=29?=
 <grubba@grubba.org>
Date: Thu, 10 Oct 2013 18:05:45 +0200
Subject: [PATCH] Backend: Fixed a few bugs in the new code.

---
 src/backend.cmod | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/backend.cmod b/src/backend.cmod
index 00d6ac77f4..ef4ba872fe 100644
--- a/src/backend.cmod
+++ b/src/backend.cmod
@@ -1035,6 +1035,7 @@ PIKECLASS Backend
 	     if(CALL(c->pos) != c)
 	       Pike_fatal("Call_out->pos not correct!\n");
 #endif
+	     UNPROTECT_CALL_OUTS();
 	     add_ref(c->args);
 	     return c->args;
 	   }
@@ -1068,7 +1069,7 @@ PIKECLASS Backend
 	 /* FIXME: Use CYCLIC! */
 	 if (is_eq(fun, ITEM(res))) {
 	   add_ref(res);
-	   pop_n_elems(save_sp - Pike_sp);
+	   pop_n_elems(Pike_sp - save_sp);
 	   return res;
 	 }
 	 pop_stack();
-- 
GitLab