From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Kevin Grittner <kgrittn(at)ymail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_archivecleanup bug |
Date: | 2014-03-18 14:15:11 |
Message-ID: | 20140318141511.GT6899@eldon.alvh.no-ip.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Bruce Momjian escribió:
> On Tue, Mar 18, 2014 at 10:03:46AM -0400, Robert Haas wrote:
> > On Tue, Mar 18, 2014 at 9:56 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> > > Bruce Momjian <bruce(at)momjian(dot)us> writes:
> > >> Very good point. I have modified the patch to add this block in all
> > >> cases where it was missing. I started to wonder about the comment and
> > >> if the Mingw fix was released. Based on some research, I see this as
> > >> fixed in mingw-runtime-3.2, released 2003-10-10. That's pretty old.
> > >
> > > Yeah. I would vote for removing that code in all branches. There is no
> > > reason to suppose somebody is going to install 8.4.22 on a machine that
> > > they haven't updated mingw on since 2003. Or, if you prefer, just remove
> > > it in HEAD --- but going around and *adding* more copies seems like
> > > make-work. The fact that we've not heard complaints about the omissions
> > > is good evidence that nobody's using the buggy mingw versions anymore.
> >
> > I don't think it is. Right now we're not checking errno *at all* in a
> > bunch of these places, so we're sure not going to get complaints about
> > doing it incorrectly in those places. Or do I need more caffeine?
>
> You are correct. This code is seriously broken and I am susprised we
> have not gotten more complaints. Good thing readdir/closedir rarely
> fail.
I think we need to keep the check for old mingw runtime in older
branches; it seems reasonable to keep updating Postgres when new
versions come out but keep mingw the same if it doesn't break. A good
criterion here, to me, is: would we make it a runtime error if an old
mingw version is detected? If we would, then let's go and remove all
those errno checks. Then we force everyone to update to a sane mingw.
But if we're not adding such a check, then we might cause subtle trouble
just because we think running old mingw is unlikely.
On another note, please let's not make the code dissimilar in some
branches just because of source code embellishments are not back-ported
out of fear. I mean, if we want them in master, let them be in older
branches as well. Otherwise we end up with slightly different versions
that make back-patching future fixes a lot harder, for no gain.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2014-03-18 14:23:44 | Re: Changeset Extraction v7.9.1 |
Previous Message | Robert Haas | 2014-03-18 14:08:57 | Re: pg_basebackup --slot=SLOTNAME -X stream |