Jean-Sébastien Bevilacqua
2017-Jul-04 15:50 UTC
[Rd] [New Patch] Fix disk corruption when writing
Hello, You can find here a patch to fix disk corruption. When your disk is full, the write function exit without error but the file is truncated. https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17243 Sincerely, Jean-S?bastien Bevilacqua [[alternative HTML version deleted]]
On 04/07/2017 11:50 AM, Jean-S?bastien Bevilacqua wrote:> Hello, > You can find here a patch to fix disk corruption. > When your disk is full, the write function exit without error but the file > is truncated. > > https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17243Thanks. I didn't see that when it came through (or did and forgot). I'll probably move the error check to a lower level (in the Rconn_printf function), if tests show that works. Duncan Murdoch
I tried the newest patch, but it does not seem to work for me (on Linux). Despite the check in Rconn_printf, the write.csv happily writes to /dev/full and does not report an error. When I added a printf("%d\n", res); to the Rconn_printf() definition, I see only positive values returned by the vfprintf call. Cheers, j. On 4 July 2017 at 21:37, Duncan Murdoch <murdoch.duncan at gmail.com> wrote:> On 04/07/2017 11:50 AM, Jean-S?bastien Bevilacqua wrote: > >> Hello, >> You can find here a patch to fix disk corruption. >> When your disk is full, the write function exit without error but the file >> is truncated. >> >> https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17243 >> > > Thanks. I didn't see that when it came through (or did and forgot). I'll > probably move the error check to a lower level (in the Rconn_printf > function), if tests show that works. > > Duncan Murdoch > > > ______________________________________________ > R-devel at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel >-- -------- January Weiner -------------------------------------- [[alternative HTML version deleted]]