[Rd] segfault with readDCF on R 3.1.2 on AIX 6.1 when using install.packages

Duncan Murdoch murdoch.duncan at gmail.com
Tue Sep 22 10:46:31 CEST 2015


On 21/09/2015 10:20 PM, Vinh Nguyen wrote:
> On Mon, Sep 21, 2015 at 2:48 PM, Duncan Murdoch
> <murdoch.duncan at gmail.com> wrote:
>> On 21/09/2015 4:50 PM, Hervé Pagès wrote:
>>> Hi,
>>>
>>> Note that one significant change to read.dcf() that happened since R
>>> 3.0.2 is the addition of support for arbitrary long lines (commit
>>> 63281), which never worked:
>>>
>>>    dcf <- paste(c("aa: ", rep(letters, length.out=10000)), collapse="")
>>>    writeLines(dcf, "test.dcf")
>>>    nchar(read.dcf("test.dcf"))
>>>    #        aa
>>>    # [1,] 8186
>>>
>>
>> I don't see that in R 3.2.2 on OSX or 3.2.2 patched on Windows:
>>
>>>    nchar(read.dcf("test.dcf"))
>>         aa
>> [1,] 10000
> 
> I'm at home now and getting the following from Revolution R Open 3.2.2 on a Mac:

You should post bug reports about that build to Revolution.  We have no
idea what changes it includes, and (being part of Microsoft) they have
tens of thousands more employees to deal with their bugs than we (being
all volunteers) do.

However, Herve's second example does illustrate a bug I can reproduce:
one character out of 10000 was read incorrectly.  Could you please try
his final patch and see if it fixes your AIX problems?

> 
>> dcf <- paste(c("aa: ", rep(letters, length.out=10000)), collapse="")
>> writeLines(dcf, "test.dcf")
>> nchar(read.dcf("test.dcf"))
>        aa
> [1,] 8186
> 
> Here's what I see in the file:
> 
> $ wc -c test.dcf
> 
>    10005 test.dcf
> 
> Same results using Revolution R Open on Windows.  Also same results on
> regular R 3.2.0 on Windows.

Version 3.2.0 is not current.

Duncan Murdoch

> 
> -- Vinh
>



More information about the R-devel mailing list