From jeff.horner at vanderbilt.edu  Thu Oct  9 16:20:10 2008
From: jeff.horner at vanderbilt.edu (Jeffrey Horner)
Date: Thu, 09 Oct 2008 09:20:10 -0500
Subject: [Rd] Expose clearPushBack for connections
Message-ID: <48EE131A.7040106@vanderbilt.edu>

Hi all,

rapache relies on embedding R and assigning it's own function to 
ptr_R_ReadConsole so that users can read HTTP POST data from a request 
with readLines() with the stdin() connection. However, since stdin() is 
a non-blocking text connection, incomplete lines are silently pushed 
back onto the connection. I don't see any other way to clear the pushed 
back data other than to call .Internal(clearPushBack(stdin()) which 
works well but may be deprecated in the future.

Are there other solutions to clear the stdin() push back stack for apps 
that embed R and use their own reading routines?

Thanks,

Jeff
-- 
http://biostat.mc.vanderbilt.edu/JeffreyHorner



[Rd] Expose clearPushBack for connections
Jeffrey Horner