seemingly random "nesting of readline input" warnings

Peter Dalgaard BSA p.dalgaard@biostat.ku.dk
02 Nov 2002 10:23:23 +0100


Roger Peng <rpeng@stat.ucla.edu> writes:

> Okay, I think I can reproduce this warning:  I startup R --vanilla,
> then type Ctrl-C 11 times.  On my machine (RedHat Linux 7.1, Athlon 1.2Ghz
> chip) the 11th Ctrl-C produces the warning.  Again, this is R 1.6.1.
> 
> When I ran R in gdb I set a break point at line 393 of src/unix/sys-std.c.
> It got triggered after the 10th Ctrl-C and when I printed ReadlineStack, I
> got
> 
> Breakpoint 1, pushReadline (prompt=0x8255dd8 "> ", 
>     f=0x813ed70 <readline_handler>) at sys-std.c:393
> 393          warning("An unusual circumstance has arisen in the nesting of
> readline input. Please report using bug.report()");
> 
> (gdb) print ReadlineStack
> $4 = {current = 9, max = 9, fun = {0x813ed70 <readline_handler>, 
>     0x813ed70 <readline_handler>, 0x813ed70 <readline_handler>, 
>     0x813ed70 <readline_handler>, 0x813ed70 <readline_handler>, 
>     0x813ed70 <readline_handler>, 0x813ed70 <readline_handler>, 
>     0x813ed70 <readline_handler>, 0x813ed70 <readline_handler>, 
>     0x813ed70 <readline_handler>}}
> 
> I hope this helps.

Argh. Yes, the ReadlineStack.current needs to be reset to zero by
something when you break out. A pragmatic temporary fix is to increase
the maximum to be large enough that you don't bump into it this
easily.

Duuuuncan! Come and fix this!

-- 
   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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._