This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [pushed] Re: [PATCH 1/6] Code cleanup: C++ify .gdb_index producer.
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: palves at redhat dot com, gdb-patches at sourceware dot org, vleschuk at accesssoftek dot com
- Date: Sun, 18 Jun 2017 18:11:28 +0300
- Subject: Re: [pushed] Re: [PATCH 1/6] Code cleanup: C++ify .gdb_index producer.
- Authentication-results: sourceware.org; auth=none
- References: <149582312757.15869.18345460438195439402.stgit@host1.jankratochvil.net> <149582313928.15869.12647134810146005233.stgit@host1.jankratochvil.net> <8efc0742-1014-4fe0-6948-f40a9c5c4975@redhat.com> <20170618142530.GA3559@host1.jankratochvil.net>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> Date: Sun, 18 Jun 2017 16:25:30 +0200
> From: Jan Kratochvil <jan.kratochvil@redhat.com>
> Cc: gdb-patches@sourceware.org, Victor Leschuk <vleschuk@accesssoftek.com>
>
> On Mon, 12 Jun 2017 18:08:07 +0200, Pedro Alves wrote:
> > + file_closer close_out_file (out_file);
> > + gdb::unlinker unlink_file (filename.c_str ());
>
> I heard on MS-Windows one cannot delete a file which is still open.
Depends on how it was open, but yeah, in general you are right. (Most
programs, especially those which were ported from Posix systems, open
files in a way that indeed precludes their deletion, because that's
what the MS implementation of 'open' does.)