Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-12 Thread Steven Schveighoffer via Digitalmars-d
On 9/4/17 2:20 AM, Brad Roberts via Digitalmars-d wrote: On 9/3/2017 1:07 PM, Rainer Schuetze via Digitalmars-d wrote: This workaround has side effects, i.e. it doesn't automatically close any file still open by the DLLs' instance of the C runtime, so it might cause incomplete files if

Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-04 Thread Brad Roberts via Digitalmars-d
On 9/3/2017 1:07 PM, Rainer Schuetze via Digitalmars-d wrote: This workaround has side effects, i.e. it doesn't automatically close any file still open by the DLLs' instance of the C runtime, so it might cause incomplete files if someone relies on these being automatically flushed and

Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-03 Thread Rainer Schuetze via Digitalmars-d
On 03.09.2017 20:21, Markus Pursche wrote: On Sunday, 3 September 2017 at 13:41:33 UTC, Rainer Schuetze wrote: On 02.09.2017 23:38, Markus Pursche wrote: [...] Unfortunately, this section only applies to simple programs (no multi-threading, no sharing of other resources than GC-memory,

Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-03 Thread Markus Pursche via Digitalmars-d
On Sunday, 3 September 2017 at 13:41:33 UTC, Rainer Schuetze wrote: On 02.09.2017 23:38, Markus Pursche wrote: [...] Unfortunately, this section only applies to simple programs (no multi-threading, no sharing of other resources than GC-memory, not even malloc'ed memory). I think there

Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-03 Thread Rainer Schuetze via Digitalmars-d
On 02.09.2017 23:38, Markus Pursche wrote: Hi, I'm trying to hot reload a DLL while the program is running to allow for rapid iteration in a game engine I am working on. I started reading up on how DLLs work between D code here:

Re: Call to Runtime.unloadLibrary corrupts stdout and stderr

2017-09-02 Thread rikki cattermole via Digitalmars-d
On 02/09/2017 10:38 PM, Markus Pursche wrote: Hi, I'm trying to hot reload a DLL while the program is running to allow for rapid iteration in a game engine I am working on. I started reading up on how DLLs work between D code here: