From xemacs-m  Sat Jun 28 15:03:42 1997
Received: from jagor.srce.hr (hniksic@jagor.srce.hr [161.53.2.130])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id PAA19032
	for <xemacs-beta@xemacs.org>; Sat, 28 Jun 1997 15:03:38 -0500 (CDT)
Received: (from hniksic@localhost)
          by jagor.srce.hr (8.8.5/8.8.4)
	  id WAA10608; Sat, 28 Jun 1997 22:03:36 +0200 (MET DST)
To: XEmacs Developers <xemacs-beta@xemacs.org>
Subject: Re: XEmacs internal corruption integer `0' plist -- test case
References: <m2k9jeppxm.fsf@altair.xemacs.org> <QQcvxt03404.199706281921@crystal.WonderWorks.COM> <m2zpsay0t2.fsf@altair.xemacs.org>
X-Attribution: Hrv
X-Face: Mie8:rOV<\c/~z{s.X4A{!?vY7{drJ([U]0O=W/<W*SMo/Mv:58:*_y~ki>xDi&N7XG
        KV^$k0m3Oe/)'e%3=$PCR&3ITUXH,cK>]bci&<qQ>Ff%x_>1`T(+M2Gg/fgndU%k*ft
        [(7._6e0n-V%|%'[c|q:;}td$#INd+;?!-V=c8Pqf}3J
From: Hrvoje Niksic <hniksic@srce.hr>
Date: 28 Jun 1997 22:03:36 +0200
In-Reply-To: Steven L Baur's message of "28 Jun 1997 12:39:21 -0700"
Message-ID: <kigzpsatrzb.fsf@jagor.srce.hr>
Lines: 56
X-Mailer: Gnus v5.4.59/XEmacs 20.3(beta9) - "Sofia"

Steven L Baur <steve@xemacs.org> writes:

> +  (or (vectorp table)
> +      (setq table (signal 'wrong-type-argument
> +			  (list 'vectorp table))))

This is a good patch, in any case.

As for the others, I would propose making `setplist' abort (in beta
releases) when someone tries to mutilate the plist of a symbol in the
obarray.

But the problem needn't be in the Lisp code at all -- it can be
either:

 - buggy C code, which can do something like
      foo->plist = make_int (0);
   whenever it likes;

 - or, even worse, some kind of memory corruption somewhere -- this
   should be tested with a memory debugging tool (anyone got purify
   out there?)

> Bad plist in origvar, 0
> 
> `origvar' is not a global symbol.  It is a let-bound symbol occurring
> in exactly one place help.el/describe-variable.

It doesn't matter -- once you create a symbol in the obarray, it will
not be uninterned unless you do it explicitly.  `let' will only change 
the symbol's value to whatever you like, and then unbind it back to
Qunbound.  For instance:

(intern-soft "no-such-symbol")
  => nil
(let ((no-such-symbol 5))
  nil)
  => nil
(intern-soft "no-such-symbol")
  => no-such-symbol

So, something else could have got hold of him later -- buggy C code,
for example.

I seem to remember the announcement of XEmacs 19.12 saying:

-- Purify (was) used to ensure that there are no memory leaks or
   memory corruption problems

I think it is time to do that test again.  Whoever of you has purify,
it is time to step out.

-- 
Hrvoje Niksic <hniksic@srce.hr> | Student at FER Zagreb, Croatia
--------------------------------+--------------------------------
"Psychos _do not_ explode when sunlight hits them."

