This is the mail archive of the
cygwin-developers
mailing list for the Cygwin project.
Re: [PATCH] winsup/cygwin: Protect fork() against dll- and exe-updates.
- From: cyg Simple <cygsimple at gmail dot com>
- To: cygwin-developers at cygwin dot com
- Date: Fri, 7 Aug 2015 11:01:59 -0400
- Subject: Re: [PATCH] winsup/cygwin: Protect fork() against dll- and exe-updates.
- Authentication-results: sourceware.org; auth=none
- References: <20150727075053 dot GD7535 at calimero dot vinschen dot de> <55B7B079 dot 7030700 at ssi-schaefer dot com> <20150729132211 dot GP7535 at calimero dot vinschen dot de> <55BB5CBC dot 6040900 at ssi-schaefer dot com> <20150803202158 dot GH17917 at calimero dot vinschen dot de>
On 8/3/2015 4:21 PM, Corinna Vinschen wrote:
>
> The HMODULE is only the address of the section so, no, there's no way to
> do an NtCreateFile with this information alone. As for the file id, I
> never tried NtOpenFile w/ FILE_OPEN_BY_FILE_ID. The usage description
> in the WDK docs is a bit vague, but it does work. You just have to have
> the file id from some earlier call to NtQueryInformationFile.
>
I seem to remember that the file id isn't guaranteed to be constant on
Windows FS, especially FAT, unless you keep the file open.
--
cyg Simple