Bug 15405 - Core dump with R --encoding=foo -e 1 (non-existing encoding)
Core dump with R --encoding=foo -e 1 (non-existing encoding)
Status: CLOSED FIXED
Product: R
Classification: Unclassified
Component: Startup
R-devel (trunk)
All All
: P5 major
Assigned To: R-core
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-28 18:50 UTC by Henrik Bengtsson
Modified: 2013-07-28 21:28 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Henrik Bengtsson 2013-07-28 18:50:47 UTC
Trying to launch R with a *non-existing* encoding core dumps/crashes,
e.g. R --encoding=foo -e 1.  (This does not occur when an existing encoding is used, e.g. R --encoding=ASCII -e 1.)


LINUX:
% R --encoding=foo -e 1
R version 3.0.0 (2013-04-03) -- "Masked Marvel"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-unknown-linux-gnu (64-bit)
[...]
> <ERROR: re-encoding failure from encoding 'foo'>

(not sure if the above is a core dump, but the expression is not
echoed/evaluated)


OSX:
> R --encoding=foo -e 1
R version 3.0.1 (2013-05-16) -- "Good Sport"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin10.8.0 (64-bit)
[...]
>
 *** caught segfault ***
address 0xffffffffffffffff, cause 'memory not mapped'
aborting ...
Segmentation fault


WINDOWS:
%R --encoding=foo -e 1 (also Rterm --encoding=foo -e 1)
R version 2.15.3 Patched (2013-03-13 r62402) -- "Security Blanket
Copyright (C) 2013 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: x86_64-w64-mingw32/x64 (64-bit)
[...]
[crashes "R for Windows terminal front-end"]

%R --encoding=foo -e 1 (also Rterm --encoding=foo -e 1)
R version 3.0.1 (2013-05-16) -- "Good Sport"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-w64-mingw32/x64 (64-bit)
[...]
[crashes "R for Windows terminal front-end"]

%R --encoding=foo -e 1 (also Rterm --encoding=foo -e 1)
R version 3.0.1 Patched (2013-07-25 r63414) -- "Good Sport"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-w64-mingw32/x64 (64-bit)
[...]
[crashes "R for Windows terminal front-end"]

%R --encoding=foo -e 1 (also Rterm --encoding=foo -e 1)
R Under development (unstable) (2013-07-26 r63419) -- "Unsuffered Consequences"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: x86_64-w64-mingw32/x64 (64-bit)
[...]
[crashes "R for Windows terminal front-end"]
Comment 1 Duncan Murdoch 2013-07-28 21:28:24 UTC
The error checking code has a minor error in it; will fix in R-devel and R-patched.