From p.dalgaard@biostat.ku.dk  Tue May 11 21:59:28 1999
From: p.dalgaard@biostat.ku.dk (Peter Dalgaard BSA)
Date: 11 May 1999 22:59:28 +0200
Subject: model.matrix crashes (PR#189)
In-Reply-To: thomas@biostat.washington.edu's message of "Tue, 11 May 1999 21:26:09 +0200 (MET DST)"
References: <199905111926.VAA21832@pubhealth.ku.dk>
Message-ID: <x2k8ufqq4v.fsf@blueberry.kubism.ku.dk>

thomas@biostat.washington.edu writes:

> On Tue, 11 May 1999 jlindsey@alpha.luc.ac.be wrote:
> 
> > With 0.64.1 on Intel RH5.2,
> > 
> > abc <- list()
> > abc$abc$abc <- matrix(1:20)
> > mt <- terms(~(abc$abc$abc[,1]==64)|(abc$abc$abc[,1]==65)|(abc$abc$abc[,1]==75)
> > 	|(abc$abc$abc[,1]==84)|(abc$abc$abc[,1]==85))
> > model.matrix(mt,model.frame(mt))
> > 
> > crashes. With ab$ab$ab, it does not. Apparently, the bug I reported
> > for 0.64.0 has just been pushed back one step. Jim
> 
> I can't reproduce this on Solaris.

I can, on Linux, RH6.0.

The problem is neatly described in src/main/model.c:1690

    /* FIXME : we need to check for buffer overflow here. */

I've upped the BUFSIZE from 128 to 4096, which should push the problem
a bit further back....

-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk)             FAX: (+45) 35327907
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


model.matrix crashes (PR#189)
Peter Dalgaard BSA