Re: [Rd] (PR#10437) segfault on functions with 'source' attribute

From: <ripley_at_stats.ox.ac.uk>
Date: Mon, 19 Nov 2007 16:50:27 +0100 (CET)


I am not sure why you would want to do that, but the C code does assume source attributes were put there by R, and changing tests from !isNull to isString in a few places will fix that.

If there is a character vector "source" attribute it should be used: that is the point of such attributes.

On Mon, 19 Nov 2007, karl_at_huftis.org wrote:

> Full_Name: Karl Ove Hufthammer
> Version: 2.6.0
> OS: Linux (Fedora 7)
> Submission from: (NULL) (129.177.61.84)
>
>
> When viewing a function that has its 'source' attribute set to a boolean or a
> numeric, R crashes with a segfault. (Setting 'source' to a character vector does
> not make R crash, however.)
>
> Steps to reproduce:
>
>> attr(lm,"source")=FALSE
>> lm
>
> *** caught segfault ***
> address 0x18, cause 'memory not mapped'
>
> ______________________________________________
> R-devel_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>

-- 
Brian D. Ripley,                  ripley_at_stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Received on Mon 19 Nov 2007 - 15:54:13 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 19 Nov 2007 - 16:30:19 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.