kylemaxxwell / rpostgresql

Automatically exported from code.google.com/p/rpostgresql
0 stars 0 forks source link

Remove snprintf calls #66

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
RS-pgsql-pqexec.c, line 90:
snprintf(errResultMsg, len + 80, "could not Retrieve the result : %s", omsg);

Use of snprintf and printf is a serious problem in an R package as it generates 
output bypasses the R session completely and therefore cannot be suppressed, 
captured, or handled as an error.

It would be far better to promote these errors to R "messages", "warnings" or 
"errors" so they can be handled appropriately by the R session.

At the very least, removing this line would be a good start.

Original issue reported on code.google.com by zach.mayer on 30 Oct 2014 at 6:11

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I apologize for my confusion, please ignore this bug report.  The error I'm 
seeing appears to come from the Postres driver itself, rather than RPostgreSQL.

Original comment by zach.mayer on 30 Oct 2014 at 8:02