Re: [R-pkg-devel] R session crash on closing a graphic device on Windows

2022-01-26 Thread Hiroaki Yutani
I see, thanks. I filed here: https://bugs.r-project.org/show_bug.cgi?id=18292 Best, Yutani 2022年1月27日(木) 1:35 Tomas Kalibera : > > Hi Yutani, > > On 1/26/22 16:42, Hiroaki Yutani wrote: > > Hi Tomas, > > > > Thanks, but, if I understand correctly, there's no room to call the > > Rust allocator's

Re: [R-pkg-devel] R session crash on closing a graphic device on Windows

2022-01-26 Thread Hiroaki Yutani
Hi Tomas, Thanks, but, if I understand correctly, there's no room to call the Rust allocator's "free" function in the case of `DevDesc`. A `DevDesc` is supposed to be freed in `GEdestroyDevDesc()` when the device is closed. If I free it by myself, it would cause double-free. So, now I'm wondering

[R-pkg-devel] R session crash on closing a graphic device on Windows

2022-01-22 Thread Hiroaki Yutani
Hi, I'm trying to create a Rust library that can implement an R graphic device[1], but the R session crashes on `dev.off()` on Windows with R 4.1.2. Strangely, it works without errors on Linux, on macOS, and even on Windows with R-devel. Looking at the stack trace below by WinDbg, the problem is