[Rd] problems with connections when applied in tryCatch

From: Joris Meys <jorismeys_at_gmail.com>
Date: Thu, 18 Aug 2011 17:53:42 +0200

Recently on stackoverflow following problem came up :


A reproducible example: When trying



No connections are shown, but after a number of calls, suddenly the message

Error in file(file, "rt") : all connections are in use

pops up. Trying to get them deleted with closeAllConnections() causes R to crash on Windows 7. Another user reported a segfault. (see the link to stackoverflow)

Although I initially thought on.exit() was somehow skipped, that's not the case. In fact, the connection couldn't be opened, so it can't be closed either. I have no clue as to why this goes wrong, but it shows there's something odd happening with the connections. For the record, I am aware that the use of the warning handler in that call is rather peculiar. But even then, R shouldn't crash.


Joris Meys
Statistical consultant

Ghent University
Faculty of Bioscience Engineering
Department of Applied mathematics, biometrics and process control

tel : +32 9 264 59 87
Disclaimer : http://helpdesk.ugent.be/e-maildisclaimer.php

R-devel_at_r-project.org mailing list
Received on Thu 18 Aug 2011 - 15:55:49 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

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 Tue 23 Aug 2011 - 11:00:21 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.

list of date sections of archive