From bcd7316d68b46f0718a9ac36c4c1a29867c10842 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fredrik=20H=C3=BCbinette=20=28Hubbe=29?= <hubbe@hubbe.net>
Date: Tue, 7 Apr 1998 20:31:49 -0700
Subject: [PATCH] bugfix

Rev: src/svalue.c:1.26
---
 src/svalue.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/svalue.c b/src/svalue.c
index 303f83916d..47c113306e 100644
--- a/src/svalue.c
+++ b/src/svalue.c
@@ -20,7 +20,7 @@
 #include "pike_macros.h"
 #include <ctype.h>
 
-RCSID("$Id: svalue.c,v 1.25 1998/04/08 02:47:28 hubbe Exp $");
+RCSID("$Id: svalue.c,v 1.26 1998/04/08 03:31:49 hubbe Exp $");
 
 struct svalue dest_ob_zero = { T_INT, 0 };
 
@@ -1036,7 +1036,6 @@ void gc_xmark_svalues(struct svalue *s, int num)
 
 void gc_check_short_svalue(union anything *u, TYPE_T type)
 {
-  if(!u->refs) return;
 #ifdef DEBUG
   gc_svalue_location=(void *)u;
 #endif
@@ -1046,6 +1045,7 @@ void gc_check_short_svalue(union anything *u, TYPE_T type)
     fatal("Cannot have a function in a short svalue.\n");
 
   case T_OBJECT:
+    if(!u->refs) return;
     if(u->object->prog)
     {
       gc_check(u->object);
@@ -1060,7 +1060,8 @@ void gc_check_short_svalue(union anything *u, TYPE_T type)
   case T_ARRAY:
   case T_MULTISET:
   case T_MAPPING:
-  case T_PROGRAM:
+  case T_PROGRAM: 
+    if(!u->refs) return;
     gc_check(u->refs);
     break;
   }
-- 
GitLab